diff options
Diffstat (limited to 'drivers/media/usb/dvb-usb-v2/af9035.c')
-rw-r--r-- | drivers/media/usb/dvb-usb-v2/af9035.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/media/usb/dvb-usb-v2/af9035.c b/drivers/media/usb/dvb-usb-v2/af9035.c index 7b9b75f..221af2b 100644 --- a/drivers/media/usb/dvb-usb-v2/af9035.c +++ b/drivers/media/usb/dvb-usb-v2/af9035.c @@ -1313,19 +1313,20 @@ static int af9035_rc_query(struct dvb_usb_device *d) if ((buf[2] + buf[3]) == 0xff) { if ((buf[0] + buf[1]) == 0xff) { /* NEC standard 16bit */ - key = buf[0] << 8 | buf[2]; + key = RC_SCANCODE_NEC(buf[0], buf[2]); } else { /* NEC extended 24bit */ - key = buf[0] << 16 | buf[1] << 8 | buf[2]; + key = RC_SCANCODE_NECX(buf[0] << 8 | buf[1], buf[2]); } } else { /* NEC full code 32bit */ - key = buf[0] << 24 | buf[1] << 16 | buf[2] << 8 | buf[3]; + key = RC_SCANCODE_NEC32(buf[0] << 24 | buf[1] << 16 | + buf[2] << 8 | buf[3]); } dev_dbg(&d->udev->dev, "%s: %*ph\n", __func__, 4, buf); - rc_keydown(d->rc_dev, key, 0); + rc_keydown(d->rc_dev, RC_TYPE_NEC, key, 0); return 0; |