]> xenbits.xensource.com Git - libvirt.git/commitdiff
The base used for conversion of USB values should be 16 not 10.
authorKlaus Ethgen <Klaus@Ethgen.de>
Tue, 27 Apr 2010 07:20:47 +0000 (09:20 +0200)
committerGuido Günther <agx@sigxcpu.org>
Tue, 27 Apr 2010 17:47:54 +0000 (19:47 +0200)
Signed-off-by: Guido Günther <agx@sigxcpu.org>
src/node_device/node_device_udev.c

index b12a49e96124bb488b49817ded0ee13f3c3a5c3a..3a5a7e2e44b6d18b9887aa68f99c1956c8fbd9ae 100644 (file)
@@ -548,8 +548,6 @@ out:
 }
 
 
-/* XXX Is 10 the correct base for the Number/Class/SubClass/Protocol
- * conversions?  */
 static int udevProcessUSBInterface(struct udev_device *device,
                                    virNodeDeviceDefPtr def)
 {
@@ -559,28 +557,28 @@ static int udevProcessUSBInterface(struct udev_device *device,
     if (udevGetUintSysfsAttr(device,
                              "bInterfaceNumber",
                              &data->usb_if.number,
-                             10) == PROPERTY_ERROR) {
+                             16) == PROPERTY_ERROR) {
         goto out;
     }
 
     if (udevGetUintSysfsAttr(device,
                              "bInterfaceClass",
                              &data->usb_if._class,
-                             10) == PROPERTY_ERROR) {
+                             16) == PROPERTY_ERROR) {
         goto out;
     }
 
     if (udevGetUintSysfsAttr(device,
                              "bInterfaceSubClass",
                              &data->usb_if.subclass,
-                             10) == PROPERTY_ERROR) {
+                             16) == PROPERTY_ERROR) {
         goto out;
     }
 
     if (udevGetUintSysfsAttr(device,
                              "bInterfaceProtocol",
                              &data->usb_if.protocol,
-                             10) == PROPERTY_ERROR) {
+                             16) == PROPERTY_ERROR) {
         goto out;
     }