summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/tda9887.c
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2007-09-14 10:13:54 +0200
committerHans Verkuil <hverkuil@xs4all.nl>2007-09-14 10:13:54 +0200
commitee8841ac8cd3158d3cc78ed87925dbf4768dd2f8 (patch)
tree6a9f00f7e18a3a85516bceb8c821a712f5aa954a /linux/drivers/media/video/tda9887.c
parent45d49155305901c4e98c65f2fb47541d59b5bcc5 (diff)
downloadmediapointer-dvb-s2-ee8841ac8cd3158d3cc78ed87925dbf4768dd2f8.tar.gz
mediapointer-dvb-s2-ee8841ac8cd3158d3cc78ed87925dbf4768dd2f8.tar.bz2
tuner: i2c_client cannot be part of the tuner struct
From: Hans Verkuil <hverkuil@xs4all.nl> The bus-based I2C subsystem allocates the i2c_client struct. So if in order to be able to convert the tuner to the bus-based I2C API the embedded i2c_client struct must be removed from the tuner struct and replaced with a pointer. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> --- linux/drivers/media/video/tda8290.c | 22 ++++++------- linux/drivers/media/video/tda9887.c | 22 ++++++------- linux/drivers/media/video/tuner-core.c | 51 ++++++++++++++++++------------- linux/drivers/media/video/tuner-driver.h | 26 +++++++-------- 4 files changed, 65 insertions(+), 56 deletions(-)
Diffstat (limited to 'linux/drivers/media/video/tda9887.c')
-rw-r--r--linux/drivers/media/video/tda9887.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/linux/drivers/media/video/tda9887.c b/linux/drivers/media/video/tda9887.c
index e21345147..cefba2a14 100644
--- a/linux/drivers/media/video/tda9887.c
+++ b/linux/drivers/media/video/tda9887.c
@@ -28,14 +28,14 @@ static int tda9887_debug;
module_param_named(debug, tda9887_debug, int, 0644);
#define tda9887_info(fmt, arg...) do {\
- printk(KERN_INFO "%s %d-%04x: " fmt, priv->t->i2c.name, \
- i2c_adapter_id(priv->t->i2c.adapter), \
- priv->t->i2c.addr, ##arg); } while (0)
+ printk(KERN_INFO "%s %d-%04x: " fmt, priv->t->i2c->name, \
+ i2c_adapter_id(priv->t->i2c->adapter), \
+ priv->t->i2c->addr, ##arg); } while (0)
#define tda9887_dbg(fmt, arg...) do {\
if (tda9887_debug) \
- printk(KERN_INFO "%s %d-%04x: " fmt, priv->t->i2c.name, \
- i2c_adapter_id(priv->t->i2c.adapter), \
- priv->t->i2c.addr, ##arg); } while (0)
+ printk(KERN_INFO "%s %d-%04x: " fmt, priv->t->i2c->name, \
+ i2c_adapter_id(priv->t->i2c->adapter), \
+ priv->t->i2c->addr, ##arg); } while (0)
struct tda9887_priv {
struct tuner_i2c_props i2c_props;
@@ -662,14 +662,14 @@ int tda9887_attach(struct tuner *t)
return -ENOMEM;
t->fe.analog_demod_priv = priv;
- priv->i2c_props.addr = t->i2c.addr;
- priv->i2c_props.adap = t->i2c.adapter;
+ priv->i2c_props.addr = t->i2c->addr;
+ priv->i2c_props.adap = t->i2c->adapter;
priv->t = t;
- strlcpy(t->i2c.name, "tda9887", sizeof(t->i2c.name));
+ strlcpy(t->i2c->name, "tda9887", sizeof(t->i2c->name));
- tda9887_info("tda988[5/6/7] found @ 0x%x (%s)\n", t->i2c.addr,
- t->i2c.driver->driver.name);
+ tda9887_info("tda988[5/6/7] found @ 0x%x (%s)\n", t->i2c->addr,
+ t->i2c->driver->driver.name);
t->fe.ops.analog_demod_ops = &tda9887_tuner_ops;