summaryrefslogtreecommitdiffstats
path: root/sys/dev/syscons/schistory.c
diff options
context:
space:
mode:
authoryokota <yokota@FreeBSD.org>2000-01-15 15:25:43 +0000
committeryokota <yokota@FreeBSD.org>2000-01-15 15:25:43 +0000
commit5db3ba7b9b236e9d8bbec14080167428916e1668 (patch)
tree17ba6cb453aac84fa60f284601f3294270a28946 /sys/dev/syscons/schistory.c
parent164674f31b90b79c19ca15d4ee3fac064d785c59 (diff)
downloadFreeBSD-src-5db3ba7b9b236e9d8bbec14080167428916e1668.zip
FreeBSD-src-5db3ba7b9b236e9d8bbec14080167428916e1668.tar.gz
This is the 3rd stage of syscons code reorganization.
- Split terminal emulation code from the main part of the driver so that we can have alternative terminal emulator modules if we like in the future. (We are not quite there yet, though.) - Put sysmouse related code in a separate file, thus, simplifying the main part of the driver. As some files are added to the source tree, you need to run config(8) before you compile a new kernel next time. You shouldn't see any functional change by this commit; this is only internal code reorganization.
Diffstat (limited to 'sys/dev/syscons/schistory.c')
-rw-r--r--sys/dev/syscons/schistory.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/dev/syscons/schistory.c b/sys/dev/syscons/schistory.c
index aa7de06..49fc6ea 100644
--- a/sys/dev/syscons/schistory.c
+++ b/sys/dev/syscons/schistory.c
@@ -44,6 +44,7 @@
#include <sys/malloc.h>
#include <machine/console.h>
+#include <machine/pc/display.h>
#include <dev/syscons/syscons.h>
@@ -120,10 +121,12 @@ sc_alloc_history_buffer(scr_stat *scp, int lines, int prev_ysize, int wait)
if (history != NULL) {
if (lines > min_lines)
extra_history_size -= lines - min_lines;
+ /* XXX error check? */
sc_vtb_init(history, VTB_RINGBUFFER, scp->xsize, lines,
NULL, wait);
+ /* FIXME: XXX no good? */
sc_vtb_clear(history, scp->sc->scr_map[0x20],
- scp->term.cur_color);
+ SC_NORM_ATTR << 8);
if (prev_history != NULL)
copy_history(prev_history, history);
scp->history_pos = sc_vtb_tail(history);
@@ -182,7 +185,8 @@ sc_free_history_buffer(scr_stat *scp, int prev_ysize)
cur_lines = sc_vtb_rows(history);
min_lines = imax(SC_HISTORY_SIZE, prev_ysize);
- extra_history_size += (cur_lines > min_lines) ? cur_lines - min_lines : 0;
+ extra_history_size += (cur_lines > min_lines) ?
+ cur_lines - min_lines : 0;
sc_vtb_destroy(history);
free(history, M_DEVBUF);
OpenPOWER on IntegriCloud