[PATCH 6/8] [media] staging: sir: make sure we are ready to receive interrupts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ensure that the timer is ready before we request interrupts.

Signed-off-by: Sean Young <sean@xxxxxxxx>
---
 drivers/staging/media/lirc/lirc_sir.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/media/lirc/lirc_sir.c b/drivers/staging/media/lirc/lirc_sir.c
index c9ca86f..058f260 100644
--- a/drivers/staging/media/lirc/lirc_sir.c
+++ b/drivers/staging/media/lirc/lirc_sir.c
@@ -338,6 +338,8 @@ static int init_port(void)
 {
 	int retval;
 
+	setup_timer(&timerlist, sir_timeout, 0);
+
 	/* get I/O port access and IRQ line */
 	if (!request_region(io, 8, KBUILD_MODNAME)) {
 		pr_err("i/o port 0x%.4x already in use.\n", io);
@@ -352,8 +354,6 @@ static int init_port(void)
 	}
 	pr_info("I/O port 0x%.4x, IRQ %d.\n", io, irq);
 
-	setup_timer(&timerlist, sir_timeout, 0);
-
 	return 0;
 }
 
-- 
2.9.3




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux