aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/video/tda8290.c
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@linuxtv.org>2008-01-06 15:52:56 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-01-25 19:04:43 -0200
commita4f263b587573f47cc6bc7ad85e5f650169d48f6 (patch)
treed6734ff3a2d7234b34086152fe08c6606973f5b2 /drivers/media/video/tda8290.c
parentb3d98135aa6e462d7e3f42a86d12483a9003a4da (diff)
V4L/DVB (6986): tda18271: share state between analog and digital tuner instances
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/tda8290.c')
-rw-r--r--drivers/media/video/tda8290.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/media/video/tda8290.c b/drivers/media/video/tda8290.c
index eab530708a4..4ac7c043889 100644
--- a/drivers/media/video/tda8290.c
+++ b/drivers/media/video/tda8290.c
@@ -502,8 +502,13 @@ static void tda8290_init_tuner(struct dvb_frontend *fe)
static void tda829x_release(struct dvb_frontend *fe)
{
- if (fe->ops.tuner_ops.release)
- fe->ops.tuner_ops.release(fe);
+ struct tda8290_priv *priv = fe->analog_demod_priv;
+
+ /* dont try to release the tuner
+ * if we didn't attach it from this module */
+ if ((priv->ver > TDA8290) && (priv->ver > TDA8295))
+ if (fe->ops.tuner_ops.release)
+ fe->ops.tuner_ops.release(fe);
kfree(fe->analog_demod_priv);
fe->analog_demod_priv = NULL;