Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1596756 > unrolled thread

[PATCH 4.9 017/153] [media] lirc_dev: LIRC_{G,S}ET_REC_MODE do not work

Started byGreg Kroah-Hartman <gregkh@linuxfoundation.org>
First post2017-03-10 10:20 +0100
Last post2017-03-10 10:20 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 4.9 017/153] [media] lirc_dev: LIRC_{G,S}ET_REC_MODE do not work Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2017-03-10 10:20 +0100

#1596756 — [PATCH 4.9 017/153] [media] lirc_dev: LIRC_{G,S}ET_REC_MODE do not work

FromGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Date2017-03-10 10:20 +0100
Subject[PATCH 4.9 017/153] [media] lirc_dev: LIRC_{G,S}ET_REC_MODE do not work
Message-ID<tjoSo-1MV-83@gated-at.bofh.it>
4.9-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Sean Young <sean@mess.org>

commit bd291208d7f5d6b2d6a033fee449a429230b06df upstream.

Since "273b902 [media] lirc_dev: use LIRC_CAN_REC() define" these
ioctls no longer work.

Signed-off-by: Sean Young <sean@mess.org>
Reviewed-by: Andi Shyti <andi.shyti@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
 drivers/media/rc/lirc_dev.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/drivers/media/rc/lirc_dev.c
+++ b/drivers/media/rc/lirc_dev.c
@@ -589,7 +589,7 @@ long lirc_dev_fop_ioctl(struct file *fil
 		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;
 		}
@@ -599,7 +599,7 @@ long lirc_dev_fop_ioctl(struct file *fil
 				  (__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;
 		}

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web