HID: wiimote: replace hid_output_raw_report with hid_hw_output_report for output...
authorBenjamin Tissoires <benjamin.tissoires@redhat.com>
Mon, 10 Feb 2014 17:58:55 +0000 (12:58 -0500)
committerJiri Kosina <jkosina@suse.cz>
Mon, 17 Feb 2014 13:57:17 +0000 (14:57 +0100)
For BT transport layer,
  ret = hid_output_raw_report(A, B, C, HID_OUTPUT_REPORT);
is equivalent to
  ret = hid_hw_output_report(A, B, C);

So use the new API where available

Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-wiimote-core.c

index d7dc6c5bc244caaf090677a647d686a3921ec2a9..d00391418d1ae307ad1ceead4ca39e289a04dfac 100644 (file)
@@ -28,14 +28,14 @@ static int wiimote_hid_send(struct hid_device *hdev, __u8 *buffer,
        __u8 *buf;
        int ret;
 
-       if (!hdev->hid_output_raw_report)
+       if (!hdev->ll_driver->output_report)
                return -ENODEV;
 
        buf = kmemdup(buffer, count, GFP_KERNEL);
        if (!buf)
                return -ENOMEM;
 
-       ret = hid_output_raw_report(hdev, buf, count, HID_OUTPUT_REPORT);
+       ret = hid_hw_output_report(hdev, buf, count);
 
        kfree(buf);
        return ret;