Commit bb806047e22f20b96fc4f2e1a8c93bfe16e552d7

Authored by aliguori
1 parent 87127161

monitor: Drop banner hiding (Jan Kiszka)

There is no use for the hide/show banner option, and it is applied
inconsistently anyway (or what makes the difference between
 -serial mon:stdio and -nographic for the monitor?). So drop this mode.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6713 c046a42c-6fe2-441c-8c8c-71466251a162
monitor.c
... ... @@ -73,7 +73,6 @@ struct Monitor {
73 73 };
74 74  
75 75 static LIST_HEAD(mon_list, Monitor) mon_list;
76   -static int hide_banner;
77 76  
78 77 static const mon_cmd_t mon_cmds[];
79 78 static const mon_cmd_t info_cmds[];
... ... @@ -2917,15 +2916,14 @@ static void term_event(void *opaque, int event)
2917 2916 if (event != CHR_EVENT_RESET)
2918 2917 return;
2919 2918  
2920   - if (!hide_banner)
2921   - monitor_printf(mon, "QEMU %s monitor - type 'help' for more "
2922   - "information\n", QEMU_VERSION);
  2919 + monitor_printf(mon, "QEMU %s monitor - type 'help' for more information\n",
  2920 + QEMU_VERSION);
2923 2921 monitor_start_input();
2924 2922 }
2925 2923  
2926 2924 static int is_first_init = 1;
2927 2925  
2928   -void monitor_init(CharDriverState *chr, int show_banner)
  2926 +void monitor_init(CharDriverState *chr)
2929 2927 {
2930 2928 Monitor *mon;
2931 2929  
... ... @@ -2936,8 +2934,6 @@ void monitor_init(CharDriverState *chr, int show_banner)
2936 2934  
2937 2935 mon = qemu_mallocz(sizeof(*mon));
2938 2936  
2939   - hide_banner = !show_banner;
2940   -
2941 2937 mon->chr = chr;
2942 2938  
2943 2939 qemu_chr_add_handlers(chr, term_can_read, term_read, term_event, mon);
... ...
monitor.h
... ... @@ -7,7 +7,7 @@
7 7  
8 8 extern Monitor *cur_mon;
9 9  
10   -void monitor_init(CharDriverState *chr, int show_banner);
  10 +void monitor_init(CharDriverState *chr);
11 11  
12 12 void monitor_suspend(Monitor *mon);
13 13 void monitor_resume(Monitor *mon);
... ...
qemu-char.c
... ... @@ -2123,7 +2123,7 @@ CharDriverState *qemu_chr_open(const char *label, const char *filename, void (*i
2123 2123 chr = qemu_chr_open(label, p, NULL);
2124 2124 if (chr) {
2125 2125 chr = qemu_chr_open_mux(chr);
2126   - monitor_init(chr, !nographic);
  2126 + monitor_init(chr);
2127 2127 } else {
2128 2128 printf("Unable to open driver: %s\n", p);
2129 2129 }
... ...
... ... @@ -5684,7 +5684,7 @@ int main(int argc, char **argv, char **envp)
5684 5684 qemu_chr_initial_reset();
5685 5685  
5686 5686 if (monitor_device && monitor_hd)
5687   - monitor_init(monitor_hd, !nographic);
  5687 + monitor_init(monitor_hd);
5688 5688  
5689 5689 for(i = 0; i < MAX_SERIAL_PORTS; i++) {
5690 5690 const char *devname = serial_devices[i];
... ...