diff options
author | Michael Krufky <mkrufky@linuxtv.org> | 2007-06-04 15:20:11 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-07-18 14:23:55 -0300 |
commit | 024cf53089f7c8e58934407f07ca2a7b5bed3b06 (patch) | |
tree | 81074f679f6fbbb74e8b78cd1c2dd9a4dcfff1cb /drivers/media/video/tda8290.c | |
parent | be2b85a13543bbaf1a141b3a54f84c1e3b059e69 (diff) | |
download | op-kernel-dev-024cf53089f7c8e58934407f07ca2a7b5bed3b06.zip op-kernel-dev-024cf53089f7c8e58934407f07ca2a7b5bed3b06.tar.gz |
V4L/DVB (5742): Tuner: define release callback for mt20xx, tda9887 and tda8290
Define tuner release callbacks for mt20xx, tda9887 and tda8290, so that
these drivers can release their own private structures themselves.
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.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/media/video/tda8290.c b/drivers/media/video/tda8290.c index 7bdf968..2614ea9 100644 --- a/drivers/media/video/tda8290.c +++ b/drivers/media/video/tda8290.c @@ -595,6 +595,14 @@ static void tda8290_init_tuner(struct i2c_client *c) /*---------------------------------------------------------------------*/ +static void tda8290_release(struct i2c_client *c) +{ + struct tuner *t = i2c_get_clientdata(c); + + kfree(t->priv); + t->priv = NULL; +} + int tda8290_init(struct i2c_client *c) { struct tda8290_priv *priv = NULL; @@ -663,6 +671,7 @@ int tda8290_init(struct i2c_client *c) t->set_radio_freq = set_radio_freq; t->has_signal = has_signal; t->standby = standby; + t->release = tda8290_release; priv->tda827x_lpsel = 0; t->mode = V4L2_TUNER_ANALOG_TV; |