mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 11:26:02 +09:00
UPSTREAM: [media] media: rc: ensure that protocols are enabled for scancode drivers
rc scancode drivers without change_protocol should have all
protocols enabled at all time. This was only true for cec and
ir-kbd-i2c.
Signed-off-by: Sean Young <sean@mess.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
(cherry picked from commit 831c4c81e8)
Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
This commit is contained in:
@@ -1638,6 +1638,9 @@ static int rc_prepare_rx_device(struct rc_dev *dev)
|
||||
|
||||
rc_proto = BIT_ULL(rc_map->rc_proto);
|
||||
|
||||
if (dev->driver_type == RC_DRIVER_SCANCODE && !dev->change_protocol)
|
||||
dev->enabled_protocols = dev->allowed_protocols;
|
||||
|
||||
if (dev->change_protocol) {
|
||||
rc = dev->change_protocol(dev, &rc_proto);
|
||||
if (rc < 0)
|
||||
|
||||
Reference in New Issue
Block a user