control_quirk seems to be evil and our buf must be "80 06 00 01 00 00 40 00" for...
authorBernhard Urban <lewurm@gmx.net>
Sat, 19 Sep 2009 20:31:54 +0000 (22:31 +0200)
committerBernhard Urban <lewurm@gmx.net>
Sat, 19 Sep 2009 20:31:54 +0000 (22:31 +0200)
usb/core/core.c
usb/core/usb.c
usb/host/ohci.c

index d9ede11aa8de766aeb2e58ad341c14e69bd22ab7..95b8091e4a175849857bd6dd7118530c60c6d08e 100644 (file)
@@ -116,7 +116,8 @@ usb_device *usb_add_device()
         * wIndex = 0
         * wLength = 8 (in Bytes!?)
         */
-       usb_control_msg(dev, 0x80, GET_DESCRIPTOR, DEVICE, 0, 64, buf, 8, 0);
+       usb_control_msg(dev, 0x80, GET_DESCRIPTOR, DEVICE << 8, 0, 64, buf, 8, 0);
+       //usb_control_msg(dev, 0x80, GET_DESCRIPTOR, DEVICE, 0, 64, buf, 8, 0);
 
        /* 
         * length (here =64) should be "number of byte to transfer", not 
@@ -297,8 +298,8 @@ u16 usb_submit_irp(usb_irp *irp)
                        /**** send token ****/
                printf("togl: %d\n", togl);
                hcdi_enqueue(td);
-               break;
 #if 0
+               break;
                memcpy(td->buffer, mybuf, td->actlen);
 #endif
 
index 1665abf131ff4b1ba75ea1f28f4be57fa9cecc07..bfb37a6960ec7e89cd37619dacd2ac6b0ae9012e 100644 (file)
@@ -143,7 +143,7 @@ u8 usb_control_msg(usb_device *dev, u8 requesttype, u8 request, u16 value, u16 i
        irp->epsize = dev->bMaxPacketSize0;
        irp->type = USB_CTRL;
 
-#if 1
+#if 0
        buf[0]=(char)requesttype;
        buf[1]=(char)request;            
        buf[2]=(char)(value >> 8);
@@ -154,7 +154,7 @@ u8 usb_control_msg(usb_device *dev, u8 requesttype, u8 request, u16 value, u16 i
        buf[6]=(char)(length);
        buf[7]=(char)(length >> 8);
 #endif
-#if 0
+#if 1
        //should be the right way around? :O
        buf[0]=(char)requesttype;
        buf[1]=(char)request;
index bf1bc6233a9c56bc6099e169f6d323fc5a2bb9cb..d78c67219f2da3d5e80e1efb6b68454e2b1112e5 100644 (file)
@@ -178,7 +178,7 @@ static void dbg_td_flag(u32 flag)
  * Enqueue a transfer descriptor.
  */
 u8 hcdi_enqueue(usb_transfer_descriptor *td) {
-       control_quirk(); //required? YES! :O ... erm... or no? :/
+       //control_quirk(); //required? YES! :O ... erm... or no? :/
        u32 tmptdbuffer;
 
        static struct endpoint_descriptor dummyconfig;