public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] media: rc: Always report LIRC repeat flag
@ 2022-07-05  8:53 Marko Mäkelä
  2022-07-05 17:43 ` Sean Young
  0 siblings, 1 reply; 8+ messages in thread
From: Marko Mäkelä @ 2022-07-05  8:53 UTC (permalink / raw)
  To: linux-media; +Cc: Sean Young, Marko Mäkelä

The flag LIRC_SCANCODE_FLAG_REPEAT was never set by rc_keydown().
Previously it was only set by rc_repeat(), but not all protocol
decoders invoke that function.

Signed-off-by: Marko Mäkelä <marko.makela@iki.fi>
---
 drivers/media/rc/rc-main.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c
index b90438a71c80..d914197245eb 100644
--- a/drivers/media/rc/rc-main.c
+++ b/drivers/media/rc/rc-main.c
@@ -786,7 +786,8 @@ static void ir_do_keydown(struct rc_dev *dev, enum rc_proto protocol,
 			  dev->last_toggle   != toggle);
 	struct lirc_scancode sc = {
 		.scancode = scancode, .rc_proto = protocol,
-		.flags = toggle ? LIRC_SCANCODE_FLAG_TOGGLE : 0,
+		.flags = (toggle ? LIRC_SCANCODE_FLAG_TOGGLE : 0) |
+		(!new_event ? LIRC_SCANCODE_FLAG_REPEAT : 0),
 		.keycode = keycode
 	};
 
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-07-09  9:15 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-05  8:53 [PATCH] media: rc: Always report LIRC repeat flag Marko Mäkelä
2022-07-05 17:43 ` Sean Young
2022-07-06 16:39   ` Marko Mäkelä
2022-07-07  8:57     ` Sean Young
2022-07-07 11:09       ` Marko Mäkelä
2022-07-08  7:42         ` Sean Young
2022-07-08  8:44           ` [PATCH] media: lirc: ensure lirc device receives repeats Marko Mäkelä
2022-07-09  9:15             ` Sean Young

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox