summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2014-04-01 21:38:39 +0200
committerPeter Wu <peter@lekensteyn.nl>2014-12-12 17:44:13 +0100
commitc7ce8c880210cdd3e296c2db7dacad1c0f6a03ac (patch)
tree53d04e4178570059aef8a8dd11d26a12d11c7b91
parentab2bfa8d34cabf61bf9cc6725c46b30cfc019a27 (diff)
downloadqemu-c7ce8c880210cdd3e296c2db7dacad1c0f6a03ac.tar.gz
unifying: fix keyboard LED for HID++ mode
-rw-r--r--hw/usb/hid-logitech-dj.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/hw/usb/hid-logitech-dj.c b/hw/usb/hid-logitech-dj.c
index 403d994457..0ab09f332d 100644
--- a/hw/usb/hid-logitech-dj.c
+++ b/hw/usb/hid-logitech-dj.c
@@ -163,7 +163,12 @@ static void hidpp_process_receiver_report(USBLtunifyState *s, HidppMsg *msg)
/* DJ reports */
switch (msg->dj_s.report_type) {
case 0x0E: /* Keyboard LEDs */
- /* ignored */
+ for (i = 0; i < MAX_DEVICES; i++) {
+ hd = &s->devices[i];
+ if (hd->hid && hd->hid->kind == HID_KEYBOARD) {
+ hid_keyboard_write(hd->hid, msg->dj_s.payload, 1);
+ }
+ }
break;
case 0x80: /* Switch and Keep-Alive */
for (i = 0; i < MAX_DEVICES; i++) {