Add new syscons option SC_NO_SUSPEND_VTYSWITCH.
This disables vty switch during suspend/resume.
This commit is contained in:
parent
c8c1cf0ca7
commit
c42946c4c1
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=105312
@ -1102,6 +1102,7 @@ options SC_NO_CUTPASTE
|
||||
options SC_NO_FONT_LOADING
|
||||
options SC_NO_HISTORY
|
||||
options SC_NO_SYSMOUSE
|
||||
options SC_NO_SUSPEND_VTYSWITCH
|
||||
|
||||
# `flags' for sc
|
||||
# 0x80 Put the video card in the VESA 800x600 dots, 16 color mode
|
||||
|
@ -45,6 +45,7 @@ SC_NORM_REV_ATTR opt_syscons.h
|
||||
SC_PIXEL_MODE opt_syscons.h
|
||||
SC_RENDER_DEBUG opt_syscons.h
|
||||
SC_TWOBUTTON_MOUSE opt_syscons.h
|
||||
SC_NO_SUSPEND_VTYSWITCH opt_syscons.h
|
||||
DEV_SC
|
||||
|
||||
VGA_ALT_SEQACCESS opt_vga.h
|
||||
|
@ -32,6 +32,7 @@ SC_NORM_REV_ATTR opt_syscons.h
|
||||
SC_PIXEL_MODE opt_syscons.h
|
||||
SC_RENDER_DEBUG opt_syscons.h
|
||||
SC_TWOBUTTON_MOUSE opt_syscons.h
|
||||
SC_NO_SUSPEND_VTYSWITCH opt_syscons.h
|
||||
|
||||
VGA_ALT_SEQACCESS opt_vga.h
|
||||
VGA_DEBUG opt_vga.h
|
||||
|
@ -93,6 +93,7 @@ SC_NORM_REV_ATTR opt_syscons.h
|
||||
SC_PIXEL_MODE opt_syscons.h
|
||||
SC_RENDER_DEBUG opt_syscons.h
|
||||
SC_TWOBUTTON_MOUSE opt_syscons.h
|
||||
SC_NO_SUSPEND_VTYSWITCH opt_syscons.h
|
||||
|
||||
VGA_ALT_SEQACCESS opt_vga.h
|
||||
VGA_DEBUG opt_vga.h
|
||||
|
@ -36,6 +36,7 @@ SC_NORM_REV_ATTR opt_syscons.h
|
||||
SC_PIXEL_MODE opt_syscons.h
|
||||
SC_RENDER_DEBUG opt_syscons.h
|
||||
SC_TWOBUTTON_MOUSE opt_syscons.h
|
||||
SC_NO_SUSPEND_VTYSWITCH opt_syscons.h
|
||||
|
||||
VGA_ALT_SEQACCESS opt_vga.h
|
||||
VGA_DEBUG opt_vga.h
|
||||
|
@ -92,6 +92,7 @@ SC_NORM_REV_ATTR opt_syscons.h
|
||||
SC_PIXEL_MODE opt_syscons.h
|
||||
SC_RENDER_DEBUG opt_syscons.h
|
||||
SC_TWOBUTTON_MOUSE opt_syscons.h
|
||||
SC_NO_SUSPEND_VTYSWITCH opt_syscons.h
|
||||
|
||||
GDC opt_gdc.h
|
||||
|
||||
|
@ -93,6 +93,7 @@ static int sc_cur_scr;
|
||||
static int
|
||||
scsuspend(device_t dev)
|
||||
{
|
||||
#ifndef SC_NO_SUSPEND_VTYSWITCH
|
||||
int retry = 10;
|
||||
static int dummy;
|
||||
sc_softc_t *sc;
|
||||
@ -107,17 +108,20 @@ scsuspend(device_t dev)
|
||||
tsleep(&dummy, 0, "scsuspend", 100);
|
||||
} while (retry--);
|
||||
|
||||
#endif
|
||||
return (0);
|
||||
}
|
||||
|
||||
static int
|
||||
scresume(device_t dev)
|
||||
{
|
||||
#ifndef SC_NO_SUSPEND_VTYSWITCH
|
||||
sc_softc_t *sc;
|
||||
|
||||
sc = &main_softc;
|
||||
sc_switch_scr(sc, sc_cur_scr);
|
||||
|
||||
#endif
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user