summaryrefslogtreecommitdiff
path: root/linux/drivers/media/common/tuners/tda18271-fe.c
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@linuxtv.org>2008-05-04 13:54:23 -0400
committerMichael Krufky <mkrufky@linuxtv.org>2008-05-04 13:54:23 -0400
commit795210ef84f3116328c8e10766f9aa019a9842b3 (patch)
tree4769f2d7ba18c526577f8f21866d0aa5dd6de88c /linux/drivers/media/common/tuners/tda18271-fe.c
parenta609e1bc62ca00624fc93702dc635e3c29c9ba02 (diff)
downloadmediapointer-dvb-s2-795210ef84f3116328c8e10766f9aa019a9842b3.tar.gz
mediapointer-dvb-s2-795210ef84f3116328c8e10766f9aa019a9842b3.tar.bz2
tda18271: abort rf band calibration loop on errors
From: Michael Krufky <mkrufky@linuxtv.org> Abort rf band calibration loop for the TDA18271HD/C2 if an error is detected. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Diffstat (limited to 'linux/drivers/media/common/tuners/tda18271-fe.c')
-rw-r--r--linux/drivers/media/common/tuners/tda18271-fe.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/linux/drivers/media/common/tuners/tda18271-fe.c b/linux/drivers/media/common/tuners/tda18271-fe.c
index b876465c9..41a7798e0 100644
--- a/linux/drivers/media/common/tuners/tda18271-fe.c
+++ b/linux/drivers/media/common/tuners/tda18271-fe.c
@@ -606,9 +606,13 @@ static int tda18271_calc_rf_filter_curve(struct dvb_frontend *fe)
goto fail;
/* rf band calibration */
- for (i = 0; priv->rf_cal_state[i].rfmax != 0; i++)
+ for (i = 0; priv->rf_cal_state[i].rfmax != 0; i++) {
+ ret =
tda18271_rf_tracking_filters_init(fe, 1000 *
priv->rf_cal_state[i].rfmax);
+ if (ret < 0)
+ goto fail;
+ }
priv->tm_rfcal = tda18271_read_thermometer(fe);
fail:
@@ -641,7 +645,10 @@ static int tda18271c2_rf_cal_init(struct dvb_frontend *fe)
tda_info("tda18271: RF tracking filter calibration complete\n");
priv->cal_initialized = true;
+ goto end;
fail:
+ tda_info("tda18271: RF tracking filter calibration failed!\n");
+end:
return ret;
}