Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

V4L/DVB (7070): Fix some tuning problems

The attached patch solves all my vdr tuning problems on a dib7000p
nova-t stick as far as I could check within the last weekend.

It disables streaming while tuning, like that the number of faulty TS
packets is reduced.

Signed-off-by: Soeren Moch <Soeren.Moch@stud.uni-hannover.de>
Signed-off-by: Patrick Boettcher <pb@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>

authored by

Soeren Moch and committed by
Mauro Carvalho Chehab
853ea132 13b83b5d

+17 -8
+6 -2
drivers/media/dvb/frontends/dib3000mc.c
··· 684 684 struct dvb_frontend_parameters *fep) 685 685 { 686 686 struct dib3000mc_state *state = fe->demodulator_priv; 687 + int ret; 688 + 689 + dib3000mc_set_output_mode(state, OUTMODE_HIGH_Z); 687 690 688 691 state->current_bandwidth = fep->u.ofdm.bandwidth; 689 692 dib3000mc_set_bandwidth(state, BANDWIDTH_TO_KHZ(fep->u.ofdm.bandwidth)); ··· 718 715 dib3000mc_get_frontend(fe, fep); 719 716 } 720 717 718 + ret = dib3000mc_tune(fe, fep); 719 + 721 720 /* make this a config parameter */ 722 721 dib3000mc_set_output_mode(state, OUTMODE_MPEG2_FIFO); 723 - 724 - return dib3000mc_tune(fe, fep); 722 + return ret; 725 723 } 726 724 727 725 static int dib3000mc_read_status(struct dvb_frontend *fe, fe_status_t *stat)
+6 -3
drivers/media/dvb/frontends/dib7000m.c
··· 1171 1171 struct dvb_frontend_parameters *fep) 1172 1172 { 1173 1173 struct dib7000m_state *state = fe->demodulator_priv; 1174 - int time; 1174 + int time, ret; 1175 + 1176 + dib7000m_set_output_mode(state, OUTMODE_HIGH_Z); 1175 1177 1176 1178 state->current_bandwidth = fep->u.ofdm.bandwidth; 1177 1179 dib7000m_set_bandwidth(state, BANDWIDTH_TO_KHZ(fep->u.ofdm.bandwidth)); ··· 1208 1206 dib7000m_get_frontend(fe, fep); 1209 1207 } 1210 1208 1209 + ret = dib7000m_tune(fe, fep); 1210 + 1211 1211 /* make this a config parameter */ 1212 1212 dib7000m_set_output_mode(state, OUTMODE_MPEG2_FIFO); 1213 - 1214 - return dib7000m_tune(fe, fep); 1213 + return ret; 1215 1214 } 1216 1215 1217 1216 static int dib7000m_read_status(struct dvb_frontend *fe, fe_status_t *stat)
+5 -3
drivers/media/dvb/frontends/dib7000p.c
··· 1128 1128 struct dvb_frontend_parameters *fep) 1129 1129 { 1130 1130 struct dib7000p_state *state = fe->demodulator_priv; 1131 - int time; 1131 + int time, ret; 1132 1132 1133 + dib7000p_set_output_mode(state, OUTMODE_HIGH_Z); 1133 1134 state->current_bandwidth = fep->u.ofdm.bandwidth; 1134 1135 dib7000p_set_bandwidth(state, BANDWIDTH_TO_KHZ(fep->u.ofdm.bandwidth)); 1135 1136 ··· 1167 1166 dib7000p_get_frontend(fe, fep); 1168 1167 } 1169 1168 1169 + ret = dib7000p_tune(fe, fep); 1170 + 1170 1171 /* make this a config parameter */ 1171 1172 dib7000p_set_output_mode(state, OUTMODE_MPEG2_FIFO); 1172 - 1173 - return dib7000p_tune(fe, fep); 1173 + return ret; 1174 1174 } 1175 1175 1176 1176 static int dib7000p_read_status(struct dvb_frontend *fe, fe_status_t *stat)