* [PATCH 09/16] media: rc: nuvoton-cir: use IR_DEFAULT_TIMEOUT and consider SAMPLE_PERIOD
@ 2015-12-30 16:43 Heiner Kallweit
0 siblings, 0 replies; only message in thread
From: Heiner Kallweit @ 2015-12-30 16:43 UTC (permalink / raw)
To: Mauro Carvalho Chehab; +Cc: linux-media
Switch to using the recently introduced IR default timeout value
(IR_DEFAULT_TIMEOUT) and consider the value of SAMPLE_PERIOD
when calculating the limit count register value.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
---
drivers/media/rc/nuvoton-cir.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/media/rc/nuvoton-cir.h b/drivers/media/rc/nuvoton-cir.h
index 0ad15d3..6a3de08 100644
--- a/drivers/media/rc/nuvoton-cir.h
+++ b/drivers/media/rc/nuvoton-cir.h
@@ -157,8 +157,8 @@ struct nvt_dev {
/* total length of CIR and CIR WAKE */
#define CIR_IOREG_LENGTH 0x0f
-/* RX limit length, 8 high bits for SLCH, 8 low bits for SLCL (0x7d0 = 2000) */
-#define CIR_RX_LIMIT_COUNT 0x7d0
+/* RX limit length, 8 high bits for SLCH, 8 low bits for SLCL */
+#define CIR_RX_LIMIT_COUNT (IR_DEFAULT_TIMEOUT / US_TO_NS(SAMPLE_PERIOD))
/* CIR Regs */
#define CIR_IRCON 0x00
--
2.6.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2015-12-30 16:46 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-30 16:43 [PATCH 09/16] media: rc: nuvoton-cir: use IR_DEFAULT_TIMEOUT and consider SAMPLE_PERIOD Heiner Kallweit
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).