OSDN Git Service
(root)
/
uclinux-h8
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6a82582
)
HID: ft260: fix an error message in ft260_i2c_write_read()
author
Dan Carpenter
<dan.carpenter@oracle.com>
Thu, 18 Mar 2021 10:39:34 +0000
(13:39 +0300)
committer
Jiri Kosina
<jkosina@suse.cz>
Fri, 19 Mar 2021 13:26:16 +0000
(14:26 +0100)
The "len" variable is uninitialize.
Fixes:
6a82582d9fa4
("HID: ft260: add usb hid to i2c host bridge driver")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-ft260.c
patch
|
blob
|
history
diff --git
a/drivers/hid/hid-ft260.c
b/drivers/hid/hid-ft260.c
index
047aa85
..
a575160
100644
(file)
--- a/
drivers/hid/hid-ft260.c
+++ b/
drivers/hid/hid-ft260.c
@@
-512,7
+512,8
@@
static int ft260_i2c_write_read(struct ft260_device *dev, struct i2c_msg *msgs)
struct hid_device *hdev = dev->hdev;
if (msgs[0].len > 2) {
- hid_err(hdev, "%s: unsupported wr len: %d\n", __func__, len);
+ hid_err(hdev, "%s: unsupported wr len: %d\n", __func__,
+ msgs[0].len);
return -EOPNOTSUPP;
}