diff options
author | Michael Hunold <devnull@localhost> | 2004-05-03 11:15:31 +0000 |
---|---|---|
committer | Michael Hunold <devnull@localhost> | 2004-05-03 11:15:31 +0000 |
commit | 30970c2a967560590b306f6965aea609d7fd3a54 (patch) | |
tree | 1546c38a1f6394165ed95326b13814661fc42477 /linux/drivers/media/dvb/ttpci/av7110_v4l.c | |
parent | a9135ebb9e7ffd0934fa6e9bd6b0a0a4e5ff912d (diff) | |
download | mediapointer-dvb-s2-30970c2a967560590b306f6965aea609d7fd3a54.tar.gz mediapointer-dvb-s2-30970c2a967560590b306f6965aea609d7fd3a54.tar.bz2 |
Overhaul frontend i2c subsystem because of the recent discussion about
the usage of the syscall interface to load binary firmware used by some
frontend drivers.
- add dvb_register_frontend_new() and dvb_unregister_frontend_new() which
register a frontend driver using the kernel i2c interface instead of the
dvb i2c interface.
- register kernel i2c interface in av7110/budget driver properly
- port stv0299 and ves1x93 to kernel i2c api
Other DVB drivers and frontend drivers still can use the old DVB i2c
interface.
Diffstat (limited to 'linux/drivers/media/dvb/ttpci/av7110_v4l.c')
-rw-r--r-- | linux/drivers/media/dvb/ttpci/av7110_v4l.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/linux/drivers/media/dvb/ttpci/av7110_v4l.c b/linux/drivers/media/dvb/ttpci/av7110_v4l.c index a70fdaa46..dac4dde47 100644 --- a/linux/drivers/media/dvb/ttpci/av7110_v4l.c +++ b/linux/drivers/media/dvb/ttpci/av7110_v4l.c @@ -38,20 +38,17 @@ #define DEBUG_VARIABLE av7110_debug extern int av7110_debug; -#include "dvb_i2c.h" #include "av7110.h" #include "av7110_hw.h" #include "av7110_av.h" #include "dvb_functions.h" - int msp_writereg(struct av7110 *av7110, u8 dev, u16 reg, u16 val) { u8 msg[5] = { dev, reg >> 8, reg & 0xff, val >> 8 , val & 0xff }; - struct dvb_i2c_bus *i2c = av7110->i2c_bus; struct i2c_msg msgs = { .flags = 0, .addr = 0x40, .len = 5, .buf = msg }; - if (i2c->xfer(i2c, &msgs, 1) != 1) { + if (i2c_transfer(&av7110->i2c_adap, &msgs, 1) != 1) { printk("av7110(%d): %s(%u = %u) failed\n", av7110->dvb_adapter->num, __FUNCTION__, reg, val); return -EIO; @@ -63,13 +60,12 @@ int msp_readreg(struct av7110 *av7110, u8 dev, u16 reg, u16 *val) { u8 msg1[3] = { dev, reg >> 8, reg & 0xff }; u8 msg2[2]; - struct dvb_i2c_bus *i2c = av7110->i2c_bus; struct i2c_msg msgs[2] = { { .flags = 0, .addr = 0x40, .len = 3, .buf = msg1 }, { .flags = I2C_M_RD, .addr = 0x40, .len = 2, .buf = msg2 } }; - if (i2c->xfer(i2c, msgs, 2) != 2) { + if (i2c_transfer(&av7110->i2c_adap, &msgs[0], 2) != 2) { printk("av7110(%d): %s(%u) failed\n", av7110->dvb_adapter->num, __FUNCTION__, reg); return -EIO; @@ -78,8 +74,6 @@ int msp_readreg(struct av7110 *av7110, u8 dev, u16 reg, u16 *val) return 0; } - - static struct v4l2_input inputs[2] = { { .index = 0, |