aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/tuners/it913x.h
diff options
context:
space:
mode:
authorAntti Palosaari <crope@iki.fi>2014-08-26 17:14:16 -0300
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2014-09-21 17:48:23 -0300
commit3b2a5e8c080da37be6135f44d236fe6b796666d9 (patch)
tree7e299163b51e52afae4717eabc6fef86adfc41d8 /drivers/media/tuners/it913x.h
parent[media] it913x: rename tuner_it913x => it913x (diff)
downloadlinux-dev-3b2a5e8c080da37be6135f44d236fe6b796666d9.tar.xz
linux-dev-3b2a5e8c080da37be6135f44d236fe6b796666d9.zip
[media] it913x: convert to I2C driver
Change the it913x driver to use the I2C high lever tuner binding model. As af9035 depends on it, add a code there to do the binding. [mchehab@osg.samsung.com: Merge 3 patches into one, because we don't want to break bisect due to the conversion] Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/tuners/it913x.h')
-rw-r--r--drivers/media/tuners/it913x.h33
1 files changed, 17 insertions, 16 deletions
diff --git a/drivers/media/tuners/it913x.h b/drivers/media/tuners/it913x.h
index 12dd36bd9e79..9789c4d2a6ea 100644
--- a/drivers/media/tuners/it913x.h
+++ b/drivers/media/tuners/it913x.h
@@ -25,21 +25,22 @@
#include "dvb_frontend.h"
-#if defined(CONFIG_MEDIA_TUNER_IT913X) || \
- (defined(CONFIG_MEDIA_TUNER_IT913X_MODULE) && defined(MODULE))
-extern struct dvb_frontend *it913x_attach(struct dvb_frontend *fe,
- struct i2c_adapter *i2c_adap,
- u8 i2c_addr,
- u8 config);
-#else
-static inline struct dvb_frontend *it913x_attach(struct dvb_frontend *fe,
- struct i2c_adapter *i2c_adap,
- u8 i2c_addr,
- u8 config)
-{
- pr_warn("%s: driver disabled by Kconfig\n", __func__);
- return NULL;
-}
-#endif
+/*
+ * I2C address
+ * 0x38, 0x3a, 0x3c, 0x3e
+ */
+struct it913x_config {
+ /*
+ * pointer to DVB frontend
+ */
+ struct dvb_frontend *fe;
+
+ /*
+ * chip version
+ * 1 = IT9135 AX
+ * 2 = IT9135 BX
+ */
+ u8 chip_ver:2;
+};
#endif