2017-11-02 13:35:54

by Sébastien Szymanski

[permalink] [raw]
Subject: [PATCH 1/3] HID: cp2112: fix interface specification URL

Signed-off-by: Sébastien Szymanski <[email protected]>
---
drivers/hid/hid-cp2112.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/hid/hid-cp2112.c b/drivers/hid/hid-cp2112.c
index 078026f..28e3c18 100644
--- a/drivers/hid/hid-cp2112.c
+++ b/drivers/hid/hid-cp2112.c
@@ -21,7 +21,7 @@
* Data Sheet:
* http://www.silabs.com/Support%20Documents/TechnicalDocs/CP2112.pdf
* Programming Interface Specification:
- * http://www.silabs.com/Support%20Documents/TechnicalDocs/AN495.pdf
+ * https://www.silabs.com/documents/public/application-notes/an495-cp2112-interface-specification.pdf
*/

#include <linux/gpio.h>
--
2.7.3


From 1583622569448587657@xxx Thu Nov 09 20:42:51 +0000 2017
X-GM-THRID: 1583203172444751191
X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread


2017-11-02 11:46:09

by Sébastien Szymanski

[permalink] [raw]
Subject: [PATCH 2/3] HID: cp2112: add HIDRAW dependency

Otherwise, with HIDRAW=n, the probe function crashes because of null
dereference of hdev->hidraw.

Fixes: 42cb6b35b9e6 ("HID: cp2112: use proper hidraw name with minor number")
Signed-off-by: Sébastien Szymanski <[email protected]>
---
drivers/hid/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/hid/Kconfig b/drivers/hid/Kconfig
index 374301f..8c7a0ce 100644
--- a/drivers/hid/Kconfig
+++ b/drivers/hid/Kconfig
@@ -230,7 +230,7 @@ config HID_CMEDIA

config HID_CP2112
tristate "Silicon Labs CP2112 HID USB-to-SMBus Bridge support"
- depends on USB_HID && I2C && GPIOLIB
+ depends on USB_HID && HIDRAW && I2C && GPIOLIB
select GPIOLIB_IRQCHIP
---help---
Support for Silicon Labs CP2112 HID USB to SMBus Master Bridge.
--
2.7.3


From 1583313071748896038@xxx Mon Nov 06 10:43:31 +0000 2017
X-GM-THRID: 1583313071748896038
X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread