Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

tty: vt: remove unused consw::con_flush_scrollback()

consw::con_flush_scrollback() is unused since commit 973c096f6a85
(vgacon: remove software scrollback support). Drop it.

Signed-off-by: "Jiri Slaby (SUSE)" <jirislaby@kernel.org>
Tested-by: Helge Deller <deller@gmx.de> # parisc STI console
Link: https://lore.kernel.org/r/20240122110401.7289-45-jirislaby@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Jiri Slaby (SUSE) and committed by
Greg Kroah-Hartman
b23bf1a4 f441aa3b

+12 -19
+12 -15
drivers/tty/vt/vt.c
··· 888 888 WARN_CONSOLE_UNLOCKED(); 889 889 890 890 set_origin(vc); 891 - if (vc->vc_sw->con_flush_scrollback) { 892 - vc->vc_sw->con_flush_scrollback(vc); 893 - } else if (con_is_visible(vc)) { 894 - /* 895 - * When no con_flush_scrollback method is provided then the 896 - * legacy way for flushing the scrollback buffer is to use 897 - * a side effect of the con_switch method. We do it only on 898 - * the foreground console as background consoles have no 899 - * scrollback buffers in that case and we obviously don't 900 - * want to switch to them. 901 - */ 902 - hide_cursor(vc); 903 - vc->vc_sw->con_switch(vc); 904 - set_cursor(vc); 905 - } 891 + if (!con_is_visible(vc)) 892 + return; 893 + 894 + /* 895 + * The legacy way for flushing the scrollback buffer is to use a side 896 + * effect of the con_switch method. We do it only on the foreground 897 + * console as background consoles have no scrollback buffers in that 898 + * case and we obviously don't want to switch to them. 899 + */ 900 + hide_cursor(vc); 901 + vc->vc_sw->con_switch(vc); 902 + set_cursor(vc); 906 903 } 907 904 908 905 /*
-4
include/linux/console.h
··· 97 97 bool blink, bool underline, bool reverse, bool italic); 98 98 void (*con_invert_region)(struct vc_data *vc, u16 *p, int count); 99 99 /* 100 - * Flush the video console driver's scrollback buffer 101 - */ 102 - void (*con_flush_scrollback)(struct vc_data *vc); 103 - /* 104 100 * Prepare the console for the debugger. This includes, but is not 105 101 * limited to, unblanking the console, loading an appropriate 106 102 * palette, and allowing debugger generated output.