tty: add no_vga option

This is mainly for UEFI systems without a VGA-compatible video card.
This commit is contained in:
Jean-Baptiste Boric 2015-11-12 17:08:12 +01:00 committed by rlfnb
parent e154914956
commit fedd2b7386

View File

@ -1538,8 +1538,10 @@ static void tty_init()
register tty_t *tp;
int s;
long disable_vga;
system_hz = sys_hz();
env_parse("no_vga", "d", 0, &disable_vga, 0, 1);
/* Initialize the terminal lines. */
memset(tty_table, '\0' , sizeof(tty_table));
@ -1555,7 +1557,7 @@ static void tty_init()
tp->tty_termios = termios_defaults;
tp->tty_icancel = tp->tty_ocancel = tp->tty_ioctl = tp->tty_close =
tp->tty_open = tty_devnop;
if (tp < tty_addr(NR_CONS)) {
if (tp < tty_addr(NR_CONS) && disable_vga != 1) {
scr_init(tp);
/* Initialize the keyboard driver. */