diff options
author | Benjamin Tissoires <benjamin.tissoires@redhat.com> | 2014-02-05 22:33:23 +0100 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2014-02-17 14:05:59 +0100 |
commit | 7e845d46b13e7730a3720e978c28117ce422edf9 (patch) | |
tree | 6696e6c38af680b7a2536f4731d106b3619c20bc /drivers/hid/hid-lg.c | |
parent | HID: remove hid_get_raw_report in struct hid_device (diff) | |
download | linux-7e845d46b13e7730a3720e978c28117ce422edf9.tar.xz linux-7e845d46b13e7730a3720e978c28117ce422edf9.zip |
HID: introduce helper to access hid_output_raw_report()
Add a helper to access hdev->hid_output_raw_report().
To convert the drivers, use the following snippets:
for i in drivers/hid/*.c
do
sed -i.bak "s/[^ \t]*->hid_output_raw_report(/hid_output_raw_report(/g" $i
done
Then manually fix for checkpatch.pl
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hid-lg.c')
-rw-r--r-- | drivers/hid/hid-lg.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/hid/hid-lg.c b/drivers/hid/hid-lg.c index 9fe9d4ac3114..76ed7e512dcf 100644 --- a/drivers/hid/hid-lg.c +++ b/drivers/hid/hid-lg.c @@ -692,7 +692,8 @@ static int lg_probe(struct hid_device *hdev, const struct hid_device_id *id) if (hdev->product == USB_DEVICE_ID_LOGITECH_WII_WHEEL) { unsigned char buf[] = { 0x00, 0xAF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; - ret = hdev->hid_output_raw_report(hdev, buf, sizeof(buf), HID_FEATURE_REPORT); + ret = hid_output_raw_report(hdev, buf, sizeof(buf), + HID_FEATURE_REPORT); if (ret >= 0) { /* insert a little delay of 10 jiffies ~ 40ms */ @@ -704,7 +705,8 @@ static int lg_probe(struct hid_device *hdev, const struct hid_device_id *id) buf[1] = 0xB2; get_random_bytes(&buf[2], 2); - ret = hdev->hid_output_raw_report(hdev, buf, sizeof(buf), HID_FEATURE_REPORT); + ret = hid_output_raw_report(hdev, buf, sizeof(buf), + HID_FEATURE_REPORT); } } |