]> git.karo-electronics.de Git - linux-beck.git/commitdiff
[media] cx25821: Remove useless struct i2c_algo_bit_data
authorEzequiel García <elezegarcia@gmail.com>
Wed, 27 Jun 2012 15:52:49 +0000 (12:52 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 30 Jul 2012 22:53:03 +0000 (19:53 -0300)
The field 'struct i2c_algo_bit_data i2c_algo' is wrongly confused with
struct i2c_algorithm. Moreover, i2c_algo field is not used since
i2c is registered using i2c_add_adpater() and not i2c_bit_add_bus().
Therefore, it's safe to remove it.
Tested by compilation only.

Signed-off-by: Ezequiel Garcia <elezegarcia@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/cx25821/cx25821-i2c.c
drivers/media/video/cx25821/cx25821.h

index 6311180f430c43e93c126b8e219c9198fa354e7b..0a44b4ea1cecf161c85ece8ead1dbce83a3607e5 100644 (file)
@@ -307,8 +307,6 @@ int cx25821_i2c_register(struct cx25821_i2c *bus)
 
        memcpy(&bus->i2c_adap, &cx25821_i2c_adap_template,
               sizeof(bus->i2c_adap));
-       memcpy(&bus->i2c_algo, &cx25821_i2c_algo_template,
-              sizeof(bus->i2c_algo));
        memcpy(&bus->i2c_client, &cx25821_i2c_client_template,
               sizeof(bus->i2c_client));
 
@@ -316,7 +314,6 @@ int cx25821_i2c_register(struct cx25821_i2c *bus)
 
        strlcpy(bus->i2c_adap.name, bus->dev->name, sizeof(bus->i2c_adap.name));
 
-       bus->i2c_algo.data = bus;
        bus->i2c_adap.algo_data = bus;
        i2c_set_adapdata(&bus->i2c_adap, &dev->v4l2_dev);
        i2c_add_adapter(&bus->i2c_adap);
index b9aa801b00a7b29c01c45334dd14d6c7c61bb978..ed525016f1657d438ba7422d046a90e1adec497f 100644 (file)
@@ -26,7 +26,6 @@
 
 #include <linux/pci.h>
 #include <linux/i2c.h>
-#include <linux/i2c-algo-bit.h>
 #include <linux/interrupt.h>
 #include <linux/delay.h>
 #include <linux/sched.h>
@@ -213,7 +212,6 @@ struct cx25821_i2c {
 
        /* i2c i/o */
        struct i2c_adapter i2c_adap;
-       struct i2c_algo_bit_data i2c_algo;
        struct i2c_client i2c_client;
        u32 i2c_rc;