Skip to contentSkip to conversation

hw/input/ps2.c: Remove remnants of printf debug

PATCH In review Peter Maydell 3 participants 4 messages Nov 1, 2020 – Nov 12, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 hw/input/ps2.c: Remove remnants of printf debug

In commit 5edab03d4040 we added tracepoints to the ps2 keyboard and mouse emulation. However we didn't remove all the debug-by-printf support. In fact there is only one printf() remaining, and it is redundant with the trace_ps2_write_mouse() event next to it. Remove the printf() and the now-unused DEBUG* macros.

---
 hw/input/ps2.c | 9 ---------
 1 file changed, 9 deletions(-)
hw/input/ps2.c +0 -9
index f8746d2f52c..72cdb80ae1c 100644
@@ -33,12 +33,6 @@
 
 #include "trace.h"
 
-/* debug PC keyboard */
-//#define DEBUG_KBD
-
-/* debug PC keyboard : only mouse */
-//#define DEBUG_MOUSE
-
 /* Keyboard Commands */
 #define KBD_CMD_SET_LEDS	0xED	/* Set keyboard leds */
 #define KBD_CMD_ECHO     	0xEE
@@ -790,9 +784,6 @@ void ps2_write_mouse(void *opaque, int val)
     PS2MouseState *s = (PS2MouseState *)opaque;
 
     trace_ps2_write_mouse(opaque, val);
-#ifdef DEBUG_MOUSE
-    printf("kbd: write mouse 0x%02x\n", val);
-#endif
     switch(s->common.write_cmd) {
     default:
     case -1:
Signature · 1 line
2.20.1
Reviewed-by on v1 1/1
#1 lore raw
Quoted 10 lines · Peter Maydell

In commit 5edab03d4040 we added tracepoints to the ps2 keyboard and mouse emulation. However we didn't remove all the debug-by-printf support. In fact there is only one printf() remaining, and it is redundant with the trace_ps2_write_mouse() event next to it. Remove the printf() and the now-unused DEBUG* macros.

---
 hw/input/ps2.c | 9 ---------
 1 file changed, 9 deletions(-)
Reviewed-by on v1 1/1
#2 lore raw
In reply to Peter Maydell
Quoted 10 lines · Peter Maydell

In commit 5edab03d4040 we added tracepoints to the ps2 keyboard and mouse emulation. However we didn't remove all the debug-by-printf support. In fact there is only one printf() remaining, and it is redundant with the trace_ps2_write_mouse() event next to it. Remove the printf() and the now-unused DEBUG* macros.

---
hw/input/ps2.c | 9 ---------

1 file changed, 9 deletions(-)
#3 lore raw
In reply to Peter Maydell
Quoted 8 lines · Peter Maydell

In commit 5edab03d4040 we added tracepoints to the ps2 keyboard and mouse emulation. However we didn't remove all the debug-by-printf support. In fact there is only one printf() remaining, and it is redundant with the trace_ps2_write_mouse() event next to it. Remove the printf() and the now-unused DEBUG* macros.

I'll take this via target-arm.next since I'm putting a pullreq together anyway.

thanks
-- PMM