Patchwork [5/7] Make USB hid devices self-powered

login
register
mail settings
Submitter riku.voipio@nokia.com
Date Dec. 3, 2009, 1:56 p.m.
Message ID <57b393d0ce466f292015c948d2d7648728b3c5cd.1259836046.git.riku.voipio@nokia.com>
Download mbox | patch
Permalink /patch/40263/
State New
Headers show

Comments

riku.voipio@nokia.com - Dec. 3, 2009, 1:56 p.m.
From: Riku Voipio <riku.voipio@nokia.com>

Simplifies power budget negotiation.

Signed-off-by: Riku Voipio <riku.voipio@nokia.com>
---
 hw/usb-hid.c |    2 +-
 hw/usb-hub.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Patch

diff --git a/hw/usb-hid.c b/hw/usb-hid.c
index f4a2a48..b099ae7 100644
--- a/hw/usb-hid.c
+++ b/hw/usb-hid.c
@@ -100,7 +100,7 @@  static const uint8_t qemu_mouse_config_descriptor[] = {
 	0x01,       /*  u8  bNumInterfaces; (1) */
 	0x01,       /*  u8  bConfigurationValue; */
 	0x04,       /*  u8  iConfiguration; */
-	0xa0,       /*  u8  bmAttributes;
+	0xe0,       /*  u8  bmAttributes;
 				 Bit 7: must be set,
 				     6: Self-powered,
 				     5: Remote wakeup,
diff --git a/hw/usb-hub.c b/hw/usb-hub.c
index e5a0938..f252301 100644
--- a/hw/usb-hub.c
+++ b/hw/usb-hub.c
@@ -113,7 +113,7 @@  static const uint8_t qemu_hub_config_descriptor[] = {
 	0x01,       /*  u8  bNumInterfaces; (1) */
 	0x01,       /*  u8  bConfigurationValue; */
 	0x00,       /*  u8  iConfiguration; */
-	0xc0,       /*  u8  bmAttributes;
+	0xe0,       /*  u8  bmAttributes;
 				 Bit 7: must be set,
 				     6: Self-powered,
 				     5: Remote wakeup,