[USBOHCI]
authorJohannes Anderwald <johannes.anderwald@reactos.org>
Thu, 29 Dec 2011 10:13:36 +0000 (10:13 +0000)
committerJohannes Anderwald <johannes.anderwald@reactos.org>
Thu, 29 Dec 2011 10:13:36 +0000 (10:13 +0000)
- Silence a few traces
- Add a hack for handling  URB_FUNCTION_CLASS_INTERFACE. The hid bus driver performs this request with zero buffer length, which is not valid. Needs more investigation

svn path=/branches/usb-bringup/; revision=54777

drivers/usb/usbohci/hardware.cpp
drivers/usb/usbohci/hub_controller.cpp
drivers/usb/usbohci/usb_queue.cpp
drivers/usb/usbohci/usb_request.cpp

index c21e4c9..4e68d66 100644 (file)
@@ -1364,7 +1364,7 @@ InterruptServiceRoutine(
     //
     // defer processing
     //
-    DPRINT1("Status %x Acknowledge %x FrameNumber %x\n", Status, Acknowledge, This->m_HCCA->CurrentFrameNumber);
+    DPRINT("Status %x Acknowledge %x FrameNumber %x\n", Status, Acknowledge, This->m_HCCA->CurrentFrameNumber);
     KeInsertQueueDpc(&This->m_IntDpcObject, (PVOID)Status, (PVOID)(DoneHead & ~1));
 
     //
index 24e08a8..6776175 100644 (file)
@@ -1634,6 +1634,12 @@ CHubController::HandleClassInterface(
     DPRINT1("Value %x\n", Urb->UrbControlVendorClassRequest.Value);
     DPRINT1("Index %x\n", Urb->UrbControlVendorClassRequest.Index);
 
+    if (Urb->UrbControlVendorClassRequest.TransferBufferLength == 0)
+    {
+        DPRINT1("Invalid request length\n");
+        return STATUS_SUCCESS;
+    }
+
     //
     // initialize setup packet
     //
index a2853fe..f3f993e 100644 (file)
@@ -620,7 +620,7 @@ CUSBQueue::TransferDescriptorCompletionCallback(
     POHCI_ENDPOINT_DESCRIPTOR EndpointDescriptor, PreviousEndpointDescriptor;
     NTSTATUS Status;
 
-    DPRINT1("CUSBQueue::TransferDescriptorCompletionCallback transfer descriptor %x\n", TransferDescriptorLogicalAddress);
+    DPRINT("CUSBQueue::TransferDescriptorCompletionCallback transfer descriptor %x\n", TransferDescriptorLogicalAddress);
 
     //
     // find transfer descriptor in control list
index f6762c0..8fe0320 100644 (file)
@@ -941,7 +941,7 @@ CUSBRequest::AllocateEndpointDescriptor(
     Descriptor->Flags |= OHCI_ENDPOINT_SET_ENDPOINT_NUMBER(GetEndpointAddress());
     Descriptor->Flags |= OHCI_ENDPOINT_SET_MAX_PACKET_SIZE(GetMaxPacketSize());
 
-    DPRINT1("Flags %x DeviceAddress %x EndpointAddress %x PacketSize %x\n", Descriptor->Flags, GetDeviceAddress(), GetEndpointAddress(), GetMaxPacketSize());
+    DPRINT("Flags %x DeviceAddress %x EndpointAddress %x PacketSize %x\n", Descriptor->Flags, GetDeviceAddress(), GetEndpointAddress(), GetMaxPacketSize());
 
     //
     // is there an endpoint descriptor