aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorAndreas Regel <andreas.regel@gmx.de>2009-11-13 16:19:54 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-12-05 15:41:31 -0500
commit1d4361718a47fba3b51f6e155524b5473a5b8d18 (patch)
tree0c0cff33eab2fc9356c476a9dba46ce755c32e18 /drivers
parentc4fa649a3beca1e311d7f244de67306673f4c285 (diff)
V4L/DVB (13358): stv090x: add an additional check for packet delineator lock in stv090x_read_status in case of a tuned DVB-S2 signal
Signed-off-by: Andreas Regel <andreas.regel@gmx.de> Signed-off-by: Manu Abraham <manu@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/dvb/frontends/stv090x.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/drivers/media/dvb/frontends/stv090x.c b/drivers/media/dvb/frontends/stv090x.c
index 647c5354300f..65ae677015e4 100644
--- a/drivers/media/dvb/frontends/stv090x.c
+++ b/drivers/media/dvb/frontends/stv090x.c
@@ -3324,7 +3324,6 @@ static enum dvbfe_search stv090x_search(struct dvb_frontend *fe, struct dvb_fron
3324 return DVBFE_ALGO_SEARCH_ERROR; 3324 return DVBFE_ALGO_SEARCH_ERROR;
3325} 3325}
3326 3326
3327/* FIXME! */
3328static int stv090x_read_status(struct dvb_frontend *fe, enum fe_status *status) 3327static int stv090x_read_status(struct dvb_frontend *fe, enum fe_status *status)
3329{ 3328{
3330 struct stv090x_state *state = fe->demodulator_priv; 3329 struct stv090x_state *state = fe->demodulator_priv;
@@ -3346,9 +3345,15 @@ static int stv090x_read_status(struct dvb_frontend *fe, enum fe_status *status)
3346 dprintk(FE_DEBUG, 1, "Delivery system: DVB-S2"); 3345 dprintk(FE_DEBUG, 1, "Delivery system: DVB-S2");
3347 reg = STV090x_READ_DEMOD(state, DSTATUS); 3346 reg = STV090x_READ_DEMOD(state, DSTATUS);
3348 if (STV090x_GETFIELD_Px(reg, LOCK_DEFINITIF_FIELD)) { 3347 if (STV090x_GETFIELD_Px(reg, LOCK_DEFINITIF_FIELD)) {
3349 reg = STV090x_READ_DEMOD(state, TSSTATUS); 3348 reg = STV090x_READ_DEMOD(state, PDELSTATUS1);
3350 if (STV090x_GETFIELD_Px(reg, TSFIFO_LINEOK_FIELD)) { 3349 if (STV090x_GETFIELD_Px(reg, PKTDELIN_LOCK_FIELD)) {
3351 *status = FE_HAS_CARRIER | FE_HAS_VITERBI | FE_HAS_SYNC | FE_HAS_LOCK; 3350 reg = STV090x_READ_DEMOD(state, TSSTATUS);
3351 if (STV090x_GETFIELD_Px(reg, TSFIFO_LINEOK_FIELD)) {
3352 *status = FE_HAS_CARRIER |
3353 FE_HAS_VITERBI |
3354 FE_HAS_SYNC |
3355 FE_HAS_LOCK;
3356 }
3352 } 3357 }
3353 } 3358 }
3354 break; 3359 break;