From 9da10a20ba6b92d9756eeaaad204e108b2b214af Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Thu, 5 Jun 2008 10:06:53 -0300 Subject: backport I2C changes on several files From: Mauro Carvalho Chehab Some I2C API change patches were committed at kernel. Backport those changes to V4L/DVB tree. Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/cs5345.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'linux/drivers/media/video/cs5345.c') diff --git a/linux/drivers/media/video/cs5345.c b/linux/drivers/media/video/cs5345.c index d7bcb6d9e..d0bdc009d 100644 --- a/linux/drivers/media/video/cs5345.c +++ b/linux/drivers/media/video/cs5345.c @@ -174,11 +174,22 @@ static int cs5345_probe(struct i2c_client *client, /* ----------------------------------------------------------------------- */ +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 26) +static const struct i2c_device_id cs5345_id[] = { + { "cs5345", 0 }, + { } +}; +MODULE_DEVICE_TABLE(i2c, cs5345_id); + +#endif static struct v4l2_i2c_driver_data v4l2_i2c_data = { .name = "cs5345", .driverid = I2C_DRIVERID_CS5345, .command = cs5345_command, .probe = cs5345_probe, +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 26) + .id_table = cs5345_id, +#endif }; #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 5, 0) -- cgit v1.2.3