summaryrefslogtreecommitdiff
path: root/linux/drivers/media/common/saa7146_i2c.c
diff options
context:
space:
mode:
authorMichael Hunold <devnull@localhost>2004-06-21 16:52:14 +0000
committerMichael Hunold <devnull@localhost>2004-06-21 16:52:14 +0000
commit5a55a75489eb0d6a3b1dfdf391f7be6f09036d64 (patch)
treed8be3f2083fb421bf90acb54cc5fb75011eb37da /linux/drivers/media/common/saa7146_i2c.c
parent532af0393d74270b67d5510647d61ed7c59db948 (diff)
downloadmediapointer-dvb-s2-5a55a75489eb0d6a3b1dfdf391f7be6f09036d64.tar.gz
mediapointer-dvb-s2-5a55a75489eb0d6a3b1dfdf391f7be6f09036d64.tar.bz2
- Replace generic saa7146 i2c name by card specific name, suggested by Uli Luckas <luckas@musoft.de>
Diffstat (limited to 'linux/drivers/media/common/saa7146_i2c.c')
-rw-r--r--linux/drivers/media/common/saa7146_i2c.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/linux/drivers/media/common/saa7146_i2c.c b/linux/drivers/media/common/saa7146_i2c.c
index 6e991a90f..9d7b806fb 100644
--- a/linux/drivers/media/common/saa7146_i2c.c
+++ b/linux/drivers/media/common/saa7146_i2c.c
@@ -400,7 +400,7 @@ static struct i2c_algorithm saa7146_algo = {
.functionality = saa7146_i2c_func,
};
-int saa7146_i2c_adapter_prepare(struct saa7146_dev *dev, struct i2c_adapter *i2c_adapter, unsigned int class, u32 bitrate)
+int saa7146_i2c_adapter_prepare(struct saa7146_dev *dev, struct i2c_adapter *i2c_adapter, u32 bitrate)
{
DEB_EE(("bitrate: 0x%08x\n",bitrate));
@@ -411,13 +411,11 @@ int saa7146_i2c_adapter_prepare(struct saa7146_dev *dev, struct i2c_adapter *i2c
saa7146_i2c_reset(dev);
if( NULL != i2c_adapter ) {
- memset(i2c_adapter,0,sizeof(struct i2c_adapter));
- strcpy(i2c_adapter->name, dev->name);
+ BUG_ON(!i2c_adapter->class);
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
i2c_adapter->data = dev;
#else
i2c_set_adapdata(i2c_adapter,dev);
- i2c_adapter->class = class;
#endif
i2c_adapter->algo = &saa7146_algo;
i2c_adapter->algo_data = NULL;