lirc_dev: LIRC_{G,S}ET_REC_MODE do not work
Subsystems (3)
Sean Young
maintainerPATCH 2/8 lirc_dev: LIRC_{G,S}ET_REC_MODE do not work
Since "273b902 [media] lirc_dev: use LIRC_CAN_REC() define" these ioctls no longer work.
Signed-off-by Sean Young <[email protected]>
Cc Andi Shyti <[email protected]>
Cc <[email protected]> # v4.8+
--- drivers/media/rc/lirc_dev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/media/rc/lirc_dev.c +2 -2
@@ -582,7 +582,7 @@ long lirc_dev_fop_ioctl(struct file *file, unsigned int cmd, unsigned long arg) result =put_user (ir->d.features, (__u32 __user *)arg);break ;case LIRC_GET_REC_MODE : -if (LIRC_CAN_REC (ir->d.features)) { +if (!LIRC_CAN_REC (ir->d.features)) { result = -ENOTTY ;break ; }
@@ -592,7 +592,7 @@ long lirc_dev_fop_ioctl(struct file *file, unsigned int cmd, unsigned long arg) (__u32 __user *)arg);break ;case LIRC_SET_REC_MODE : -if (LIRC_CAN_REC (ir->d.features)) { +if (!LIRC_CAN_REC (ir->d.features)) { result = -ENOTTY ;break ; }
Signature · 1 line
2.9.3
Quoted 6 lines
Since "273b902 [media]
lirc_dev: useLIRC_CAN_REC()define" these ioctls no longer work.Signed-off-by Sean Young <[email protected]>Cc Andi Shyti <[email protected]>Cc <[email protected]> # v4.8+
mmhhh... yes, right! :)
Reviewed-by Andi Shyti <[email protected]>
Thanks,
Andi
Quoted 30 lines
--- drivers/media/rc/lirc_dev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/media/rc/lirc_dev.c +2
-2@@ -582,7 +582,7 @@ long lirc_dev_fop_ioctl(struct file *file, unsigned int cmd, unsigned long arg) result =put_user (ir->d.features, (__u32 __user *)arg);break ;case LIRC_GET_REC_MODE : -if (LIRC_CAN_REC (ir->d.features)) { +if (!LIRC_CAN_REC (ir->d.features)) { result = -ENOTTY ;break ; }@@ -592,7 +592,7 @@ long lirc_dev_fop_ioctl(struct file *file, unsigned int cmd, unsigned long arg) (__u32 __user *)arg);break ;case LIRC_SET_REC_MODE : -if (LIRC_CAN_REC (ir->d.features)) { +if (!LIRC_CAN_REC (ir->d.features)) { result = -ENOTTY ;break ; }Signature · 1 line
2.9.3