aboutsummaryrefslogtreecommitdiff
path: root/hw/input/adb-kbd.c
diff options
context:
space:
mode:
authorMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>2018-03-05 21:51:13 +0000
committerDavid Gibson <david@gibson.dropbear.id.au>2018-03-06 13:16:29 +1100
commit9d9769c2082bc0bdb88d0f138c5aae562b0c1826 (patch)
treeb710822543d0a844e3198a671275546f1566a803 /hw/input/adb-kbd.c
parent8d622594201286ddbb9e2dbf32a9e65c060ed4ed (diff)
downloadqemu-9d9769c2082bc0bdb88d0f138c5aae562b0c1826.zip
qemu-9d9769c2082bc0bdb88d0f138c5aae562b0c1826.tar.gz
qemu-9d9769c2082bc0bdb88d0f138c5aae562b0c1826.tar.bz2
adb: add trace-events for monitoring keyboard/mouse during bus enumeration
This is useful to help diagnose problems related to address clashes during MacOS 9 boot. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw/input/adb-kbd.c')
-rw-r--r--hw/input/adb-kbd.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/input/adb-kbd.c b/hw/input/adb-kbd.c
index 266aed1..50b6271 100644
--- a/hw/input/adb-kbd.c
+++ b/hw/input/adb-kbd.c
@@ -258,6 +258,7 @@ static int adb_kbd_request(ADBDevice *d, uint8_t *obuf,
case ADB_CMD_CHANGE_ID_AND_ACT:
case ADB_CMD_CHANGE_ID_AND_ENABLE:
d->devaddr = buf[1] & 0xf;
+ trace_adb_kbd_request_change_addr(d->devaddr);
break;
default:
d->devaddr = buf[1] & 0xf;
@@ -269,6 +270,9 @@ static int adb_kbd_request(ADBDevice *d, uint8_t *obuf,
if (buf[2] == 1 || buf[2] == 2 || buf[2] == 3) {
d->handler = buf[2];
}
+
+ trace_adb_kbd_request_change_addr_and_handler(d->devaddr,
+ d->handler);
break;
}
}