IR Toy / IR Droid USB driver
Subsystems (4)
Sean Young
maintainerv4 cover IR Toy / IR Droid USB driver
changes since v3:
fix embarassing compilation failure
make driver more robust against malicious fake device
changes since v2:
review comments from Oliver Neukum <[email protected]>
changes since v1:
v1 was a serio driver, this has now been re-written to be a USB driver. This requires a blacklist in the usb cdc-acm driver.
This also allows us to feed IR data to the device from the urb callback handler, which reduces the chance of unwanted gaps in the transmission.
Sean Young (3):
media: rc: add support for Infrared Toy and IR Droid devices
USB: cdc-acm: blacklist IR Droid / IR Toy device
MAINTAINERS: rc core and lirc maintainership
MAINTAINERS | 13 + drivers/media/rc/Kconfig | 11 + drivers/media/rc/Makefile | 1 + drivers/media/rc/ir_toy.c | 509 ++++++++++++++++++++++++++++++++++++ drivers/usb/class/cdc-acm.c | 6 + 5 files changed, 540 insertions(+) create mode 100644 drivers/media/rc/ir_toy.c
Signature · 1 line
2.26.2
Sean Young
maintainerPATCH v4 1/3 media: rc: add support for Infrared Toy and IR Droid devices
http://dangerousprototypes.com/docs/USB_Infrared_Toy
https://www.irdroid.com/irdroid-usb-ir-transceiver/
--- drivers/media/rc/Kconfig | 11 + drivers/media/rc/Makefile | 1 + drivers/media/rc/ir_toy.c | 509 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 521 insertions(+) create mode 100644 drivers/media/rc/ir_toy.c
drivers/media/rc/Kconfig +11 -0
@@ -530,6 +530,17 @@ config IR_ZX To compile this driver as a module, choose M here: the module will be called zx-irdec. +config IR_TOY + tristate "Infrared Toy and IR Droid" + depends on RC_CORE + depends on USB_ARCH_HAS_HCD + help + Say Y here if you want to use the Infrared Toy or IR Droid, USB + versions. + + To compile this driver as a module, choose M here: the module will be + called ir_toy. + endif #RC_DEVICES endif #RC_CORE
drivers/media/rc/Makefile +1 -0
@@ -50,3 +50,4 @@ obj-$(CONFIG_IR_MTK) += mtk-cir.o obj-$(CONFIG_IR_ZX) += zx-irdec.o obj-$(CONFIG_IR_TANGO) += tango-ir.o obj-$(CONFIG_RC_XBOX_DVD) += xbox_remote.o +obj-$(CONFIG_IR_TOY) += ir_toy.o
drivers/media/rc/ir_toy.c new file +509 -0
509 lines not on this page · raw message
Signature · 1 line
2.26.2
Sean Young
maintainerPATCH v4 2/3 USB: cdc-acm: blacklist IR Droid / IR Toy device
In reply to Sean YoungThe IR Droid / IR Toy device used custom protocol over serial line, so it is presenting itself as CDC ACM device.
Now that we have proper in-kernel driver for it we need to black-list the device in cdc-acm driver.
http://dangerousprototypes.com/docs/USB_Infrared_Toy
https://www.irdroid.com/irdroid-usb-ir-transceiver/
--- drivers/usb/class/cdc-acm.c | 6 ++++++ 1 file changed, 6 insertions(+)
drivers/usb/class/cdc-acm.c +6 -0
@@ -1864,6 +1864,12 @@ static const struct usb_device_id acm_ids[] = { },#endif +#if IS_ENABLED (CONFIG_IR_TOY ) + { USB_DEVICE(0x04d8, 0xfd08), + .driver_info = IGNORE_DEVICE, + }, +#endif +/*Samsung phone in firmware update mode */ { USB_DEVICE(0x04e8, 0x685d), .driver_info = IGNORE_DEVICE,
Signature · 1 line
2.26.2
Sean Young
maintainerPATCH v4 3/3 MAINTAINERS: rc core and lirc maintainership
In reply to Sean YoungThis has been maintained for some time, update MAINTAINERS to reflect.
--- MAINTAINERS | 13 +++++++++++++ 1 file changed, 13 insertions(+)
MAINTAINERS +13 -0
@@ -14190,6 +14190,19 @@ L: [email protected] S: Orphan F: drivers/net/wireless/ray* +RC CORE / LIRC FRAMEWORK +M: Sean Young <[email protected]> +L: [email protected] +S: Supported +W: http://linuxtv.org +T: git git://linuxtv.org/media_tree.git +F: Documentation/driver-api/media/rc-core.rst +F: Documentation/userspace-api/media/rc/ +F: drivers/media/rc/ +F: include/media/rc-map.h +F: include/media/rc-core.h +F: include/uapi/linux/lirc.h + RCMM REMOTE CONTROLS DECODER M: Patrick Lerda <[email protected]> S: Maintained
Signature · 1 line
2.26.2