Hi guys,

it looks like the latest 2.3.1 release (well earlier versions too)
are missing some tweaks in order to run on ppc after usb changes in
linux-2.6.11

could you merge the attached patch ?
it was aproved by the mandriva/mandrake kernel maintainer
and i did it consulting patch-2.6.11.bz2

best,

svetljo


-- 
+++ Neu: Echte DSL-Flatrates von GMX - Surfen ohne Limits +++
Always online ab 4,99 Euro/Monat: http://www.gmx.net/de/go/dsl
--- eagle_usb/driver/eu_main.c~	2005-01-17 20:54:42.000000000 +0000
+++ eagle_usb/driver/eu_main.c	2005-04-19 09:53:13.909748456 +0100
@@ -354,13 +354,21 @@
 #ifdef LINUX_2_6
     struct usb_device *usb = interface_to_usbdev (intf);
 #endif
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,11)
+    uint32_t  pid  = le16_to_cpu(usb->descriptor.idProduct);
+#else
     uint32_t  pid  = usb->descriptor.idProduct;
+#endif
     
     
     eu_enters (DBG_INIT);
     
     eu_dbg (DBG_INIT,"vid (%#X) pid (%#X) \n",
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,11)
+             le16_to_cpu(usb->descriptor.idVendor), le16_to_cpu(usb->descriptor.idProduct));
+#else
              usb->descriptor.idVendor, usb->descriptor.idProduct);
+#endif
 
     /*
      * This driver knows only pre and postfirmware devices.
@@ -419,7 +427,11 @@
 {
     eu_instance_t *ins    = NULL;
     int            ret;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,11)
+    uint32_t       pid    = le16_to_cpu(usb->descriptor.idProduct);
+#else   
     uint32_t       pid    = usb->descriptor.idProduct;
+#endif 
 
     eu_enters (DBG_INIT);
     
@@ -869,7 +881,11 @@
     struct usb_device *usb = interface_to_usbdev (intf);
 #endif
     
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,11)
+    uint32_t pid = le16_to_cpu(usb->descriptor.idProduct);
+#else
     uint32_t pid = usb->descriptor.idProduct;
+#endif
 
     eu_enters (DBG_INIT);
     
@@ -1271,7 +1287,11 @@
 #endif    
     eu_instance_t *ins;
     int retval = -ENOTTY;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,11)
+    uint32_t pid = le16_to_cpu(dev->descriptor.idProduct);
+#else    
     uint32_t pid = dev->descriptor.idProduct;
+#endif    
 
     /*
      * USB automatically transfers user ioctl structure in kernel
@@ -1747,9 +1767,15 @@
     if (ins->usbdev != NULL)
     {
         p += sprintf (p,"Vendor ID : 0x%x     Product ID : 0x%x   Rev: 0x%x\n",
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,11)
+                      le16_to_cpu(ins->usbdev->descriptor.idVendor),
+                      le16_to_cpu(ins->usbdev->descriptor.idProduct),
+                      le16_to_cpu(ins->usbdev->descriptor.bcdDevice));
+#else
                       ins->usbdev->descriptor.idVendor,
                       ins->usbdev->descriptor.idProduct,
                       ins->usbdev->descriptor.bcdDevice);
+#endif
         p += sprintf(p, "USB Bus : %03d\t USB Device : %03d\t Dbg mask: 0x%x\n",
                      ins->usbdev->bus->busnum, ins->usbdev->devnum, module_dbg_mask);
     }

Reply via email to