diff mbox series

[-next] HID: logitech-dj: check return value of hid_hw_raw_request()

Message ID 20190425023647.67463-1-yuehaibing@huawei.com (mailing list archive)
State Mainlined
Commit dbcbabf7da921f98beefb4a6f4b91eb62d072076
Delegated to: Jiri Kosina
Headers show
Series [-next] HID: logitech-dj: check return value of hid_hw_raw_request() | expand

Commit Message

Yue Haibing April 25, 2019, 2:36 a.m. UTC
hid_hw_raw_request may fails, we should return the
return value to callers.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/hid/hid-logitech-dj.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/hid/hid-logitech-dj.c b/drivers/hid/hid-logitech-dj.c
index 64e68ac871cb..a3e94f15213a 100644
--- a/drivers/hid/hid-logitech-dj.c
+++ b/drivers/hid/hid-logitech-dj.c
@@ -1131,7 +1131,7 @@  static int logi_dj_recv_query_hidpp_devices(struct dj_receiver_dev *djrcv_dev)
 				    HID_REQ_SET_REPORT);
 
 	kfree(hidpp_report);
-	return 0;
+	return retval;
 }
 
 static int logi_dj_recv_query_paired_devices(struct dj_receiver_dev *djrcv_dev)