usb/118915: usbhidctl appears to not report features and write
size correctly
Maurice Castro
maurice at castro.aus.net
Thu Dec 20 19:30:03 PST 2007
The following reply was made to PR usb/118915; it has been noted by GNATS.
From: Maurice Castro <maurice at castro.aus.net>
To: bug-followup at FreeBSD.org, Maurice Castro <maurice at atum.castro.aus.net>
Cc:
Subject: Re: usb/118915: usbhidctl appears to not report features and write size correctly
Date: Fri, 21 Dec 2007 14:07:26 +1100
--Apple-Mail-1-855914301
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
charset=US-ASCII;
delsp=yes;
format=flowed
Update to patch as the hid_report_size function is used
inconsistently with the documentation in another spot:
--Apple-Mail-1-855914301
Content-Transfer-Encoding: 7bit
Content-Type: application/octet-stream;
x-unix-mode=0644;
name=usbhidctl.diff
Content-Disposition: attachment;
filename=usbhidctl.diff
--- /usr/src/usr.bin/usbhidctl/usbhid.c Mon May 26 14:58:26 2003
+++ ./usbhid.c Fri Dec 21 13:21:19 2007
@@ -148,13 +148,13 @@
}
}
hid_end_parse(d);
- size = hid_report_size(r, 0, hid_input);
+ size = hid_report_size(r, hid_input, 0);
printf("Total input size %d bytes\n", size);
- size = hid_report_size(r, 0, hid_output);
+ size = hid_report_size(r, hid_output, 0);
printf("Total output size %d bytes\n", size);
- size = hid_report_size(r, 0, hid_feature);
+ size = hid_report_size(r, hid_feature, 0);
printf("Total feature size %d bytes\n", size);
}
@@ -219,7 +219,7 @@
}
hid_end_parse(d);
rev(&hids);
- dlen = hid_report_size(rd, 0, hid_input);
+ dlen = hid_report_size(rd, hid_input, 0);
dbuf = malloc(dlen);
if (!loop)
if (ioctl(f, USB_SET_IMMED, &one) < 0) {
--Apple-Mail-1-855914301--
More information about the freebsd-usb
mailing list