Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/hidclass.sys/device.c | 11 ++++++++++- dlls/ntoskrnl.exe/tests/driver_hid.c | 4 ++-- 2 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/dlls/hidclass.sys/device.c b/dlls/hidclass.sys/device.c index 8a57516d5d5..123feeb6032 100644 --- a/dlls/hidclass.sys/device.c +++ b/dlls/hidclass.sys/device.c @@ -356,7 +356,16 @@ static void hid_device_xfer_report( BASE_DEVICE_EXTENSION *ext, ULONG code, IRP packet.reportBufferLen--; }
- call_minidriver( code, ext->u.pdo.parent_fdo, NULL, 0, &packet, sizeof(packet), &irp->IoStatus ); + switch (code) + { + case IOCTL_HID_GET_FEATURE: + case IOCTL_HID_GET_INPUT_REPORT: + call_minidriver( code, ext->u.pdo.parent_fdo, NULL, 0, &packet, sizeof(packet), &irp->IoStatus ); + break; + case IOCTL_HID_SET_OUTPUT_REPORT: + call_minidriver( code, ext->u.pdo.parent_fdo, NULL, sizeof(packet), &packet, 0, &irp->IoStatus ); + break; + } }
static void HID_set_to_device( DEVICE_OBJECT *device, IRP *irp ) diff --git a/dlls/ntoskrnl.exe/tests/driver_hid.c b/dlls/ntoskrnl.exe/tests/driver_hid.c index 422b9b74daa..8ddbfe3850f 100644 --- a/dlls/ntoskrnl.exe/tests/driver_hid.c +++ b/dlls/ntoskrnl.exe/tests/driver_hid.c @@ -549,8 +549,8 @@ static NTSTATUS WINAPI driver_internal_ioctl(DEVICE_OBJECT *device, IRP *irp) { HID_XFER_PACKET *packet = irp->UserBuffer; ULONG expected_size = 2; - todo_wine ok(in_size == sizeof(*packet), "got input size %u\n", in_size); - todo_wine ok(!out_size, "got output size %u\n", out_size); + ok(in_size == sizeof(*packet), "got input size %u\n", in_size); + ok(!out_size, "got output size %u\n", out_size);
todo_wine_if(packet->reportId == 0x5a) ok(packet->reportId == report_id, "got id %u\n", packet->reportId);