console: Replace conditional debug messages by trace methods
Signed-off-by: Stefan Weil <sw@weilnetz.de> Reviewed-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
parent
1226961622
commit
5d28b0e960
@ -1010,6 +1010,8 @@ dma_map_wait(void *dbs) "dbs=%p"
|
|||||||
|
|
||||||
# ui/console.c
|
# ui/console.c
|
||||||
console_gfx_new(void) ""
|
console_gfx_new(void) ""
|
||||||
|
console_putchar_csi(int esc_param0, int esc_param1, int ch, int nb_esc_params) "escape sequence CSI%d;%d%c, %d parameters"
|
||||||
|
console_putchar_unhandled(int ch) "unhandled escape character '%c'"
|
||||||
console_txt_new(int w, int h) "%dx%d"
|
console_txt_new(int w, int h) "%dx%d"
|
||||||
console_select(int nr) "%d"
|
console_select(int nr) "%d"
|
||||||
console_refresh(int interval) "interval %d ms"
|
console_refresh(int interval) "interval %d ms"
|
||||||
|
11
ui/console.c
11
ui/console.c
@ -29,7 +29,6 @@
|
|||||||
#include "sysemu/char.h"
|
#include "sysemu/char.h"
|
||||||
#include "trace.h"
|
#include "trace.h"
|
||||||
|
|
||||||
//#define DEBUG_CONSOLE
|
|
||||||
#define DEFAULT_BACKSCROLL 512
|
#define DEFAULT_BACKSCROLL 512
|
||||||
#define MAX_CONSOLES 12
|
#define MAX_CONSOLES 12
|
||||||
#define CONSOLE_CURSOR_PERIOD 500
|
#define CONSOLE_CURSOR_PERIOD 500
|
||||||
@ -867,10 +866,8 @@ static void console_putchar(QemuConsole *s, int ch)
|
|||||||
s->nb_esc_params++;
|
s->nb_esc_params++;
|
||||||
if (ch == ';')
|
if (ch == ';')
|
||||||
break;
|
break;
|
||||||
#ifdef DEBUG_CONSOLE
|
trace_console_putchar_csi(s->esc_params[0], s->esc_params[1],
|
||||||
fprintf(stderr, "escape sequence CSI%d;%d%c, %d parameters\n",
|
ch, s->nb_esc_params);
|
||||||
s->esc_params[0], s->esc_params[1], ch, s->nb_esc_params);
|
|
||||||
#endif
|
|
||||||
s->state = TTY_STATE_NORM;
|
s->state = TTY_STATE_NORM;
|
||||||
switch(ch) {
|
switch(ch) {
|
||||||
case 'A':
|
case 'A':
|
||||||
@ -984,9 +981,7 @@ static void console_putchar(QemuConsole *s, int ch)
|
|||||||
s->y = s->y_saved;
|
s->y = s->y_saved;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
#ifdef DEBUG_CONSOLE
|
trace_console_putchar_unhandled(ch);
|
||||||
fprintf(stderr, "unhandled escape character '%c'\n", ch);
|
|
||||||
#endif
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user