Author: janderwald
Date: Thu Jan 5 01:24:11 2012
New Revision: 54837
URL:
http://svn.reactos.org/svn/reactos?rev=54837&view=rev
Log:
[USB-BRINGUP]
- Fix creating instance id
- Print debug message
- Sync msmouse with head and add hid installation
- Needs input.inf written
- HID stack starts to initializes and then fails the to enable the device interface
(/drivers/hid/hidclass/pdo.c:511), Logs show that IoGetDeviceObjectPointer() fails with
STATUS_UNSUCCESSFUL
Modified:
branches/usb-bringup/drivers/hid/hidclass/pdo.c
branches/usb-bringup/drivers/usb/usbhub_new/fdo.c
branches/usb-bringup/media/inf/msmouse.inf
Modified: branches/usb-bringup/drivers/hid/hidclass/pdo.c
URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup/drivers/hid/hidclas…
==============================================================================
--- branches/usb-bringup/drivers/hid/hidclass/pdo.c [iso-8859-1] (original)
+++ branches/usb-bringup/drivers/hid/hidclass/pdo.c [iso-8859-1] Thu Jan 5 01:24:11 2012
@@ -501,15 +501,16 @@
// now register the device interface
//
Status =
IoRegisterDeviceInterface(PDODeviceExtension->Common.HidDeviceExtension.PhysicalDeviceObject,
&GUID_DEVINTERFACE_HID, NULL, &PDODeviceExtension->DeviceInterface);
+ DPRINT1("[HIDCLASS] IoRegisterDeviceInterfaceState Status %x\n",
Status);
if (NT_SUCCESS(Status))
{
//
// enable device interface
//
Status =
IoSetDeviceInterfaceState(&PDODeviceExtension->DeviceInterface, TRUE);
+ DPRINT1("[HIDCLASS] IoSetDeviceInterFaceState %x\n", Status);
}
ASSERT(Status == STATUS_SUCCESS);
-
//
// break
//
Modified: branches/usb-bringup/drivers/usb/usbhub_new/fdo.c
URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup/drivers/usb/usbhub_…
==============================================================================
--- branches/usb-bringup/drivers/usb/usbhub_new/fdo.c [iso-8859-1] (original)
+++ branches/usb-bringup/drivers/usb/usbhub_new/fdo.c [iso-8859-1] Thu Jan 5 01:24:11
2012
@@ -803,6 +803,7 @@
NTSTATUS Status;
ULONG Index;
PWCHAR BufferPtr;
+ WCHAR Buffer[100];
PHUB_CHILDDEVICE_EXTENSION UsbChildExtension;
UsbChildExtension =
(PHUB_CHILDDEVICE_EXTENSION)UsbChildDeviceObject->DeviceExtension;
@@ -959,7 +960,7 @@
//
// the device did not provide a serial number, lets create a pseudo instance id
//
- Index = swprintf(BufferPtr,
L"USB\\Vid_%04x&Pid_%04x&1A0700BC\0",
UsbChildExtension->DeviceDesc.idVendor, UsbChildExtension->DeviceDesc.idProduct) +
1;
+ Index = swprintf(Buffer, L"0&%04d",
UsbChildExtension->PortNumber) + 1;
UsbChildExtension->usInstanceId.Buffer = (LPWSTR)ExAllocatePool(NonPagedPool,
Index * sizeof(WCHAR));
if (UsbChildExtension->usInstanceId.Buffer == NULL)
{
@@ -970,7 +971,7 @@
//
// copy instance id
//
- RtlCopyMemory(UsbChildExtension->usInstanceId.Buffer, BufferPtr,
wcslen(BufferPtr) * sizeof(WCHAR));
+ RtlCopyMemory(UsbChildExtension->usInstanceId.Buffer, Buffer, wcslen(Buffer) *
sizeof(WCHAR));
UsbChildExtension->usInstanceId.Length =
UsbChildExtension->usDeviceId.MaximumLength = Index * sizeof(WCHAR);
DPRINT1("usDeviceId %wZ\n", &UsbChildExtension->usInstanceId);
Modified: branches/usb-bringup/media/inf/msmouse.inf
URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup/media/inf/msmouse.i…
==============================================================================
Binary files - no diff available.