Skip to content

Commit 48e4cc2

Browse files
Johannes StezenbachLinus Torvalds
authored andcommitted
[PATCH] dvb: DVB update
Increase some timeouts by a factor of 10 as suggested by Mikko Hamalainen and Timo Ketolainen, to improve tuning for QAM128 / weak signal. Signed-off-by: Johannes Stezenbach <js@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
1 parent 80064b8 commit 48e4cc2

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

‎drivers/media/dvb/frontends/stv0297.c‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -617,7 +617,7 @@ static int stv0297_set_frontend(struct dvb_frontend *fe, struct dvb_frontend_par
617617

618618
/* wait for WGAGC lock */
619619
starttime = jiffies;
620-
timeout = jiffies + (200 * HZ) / 1000;
620+
timeout = jiffies + msecs_to_jiffies(2000);
621621
while (time_before(jiffies, timeout)) {
622622
msleep(10);
623623
if (stv0297_readreg(state, 0x43) & 0x08)
@@ -629,7 +629,7 @@ static int stv0297_set_frontend(struct dvb_frontend *fe, struct dvb_frontend_par
629629
msleep(20);
630630

631631
/* wait for equaliser partial convergence */
632-
timeout = jiffies + (50 * HZ) / 1000;
632+
timeout = jiffies + msecs_to_jiffies(500);
633633
while (time_before(jiffies, timeout)) {
634634
msleep(10);
635635

@@ -642,7 +642,7 @@ static int stv0297_set_frontend(struct dvb_frontend *fe, struct dvb_frontend_par
642642
}
643643

644644
/* wait for equaliser full convergence */
645-
timeout = jiffies + (delay * HZ) / 1000;
645+
timeout = jiffies + msecs_to_jiffies(delay);
646646
while (time_before(jiffies, timeout)) {
647647
msleep(10);
648648

@@ -659,7 +659,7 @@ static int stv0297_set_frontend(struct dvb_frontend *fe, struct dvb_frontend_par
659659
stv0297_writereg_mask(state, 0x88, 8, 0);
660660

661661
/* wait for main lock */
662-
timeout = jiffies + (20 * HZ) / 1000;
662+
timeout = jiffies + msecs_to_jiffies(20);
663663
while (time_before(jiffies, timeout)) {
664664
msleep(10);
665665

0 commit comments

Comments
 (0)