]> err.no Git - linux-2.6/commitdiff
i2c-algo-bit: Discard the mdelay data struct member
authorJean Delvare <khali@linux-fr.org>
Sun, 27 Aug 2006 09:46:49 +0000 (11:46 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 26 Sep 2006 22:38:51 +0000 (15:38 -0700)
i2c-algo-bit: Discard the mdelay data struct member

The i2c_algo_bit_data structure has an mdelay member, which is not
used by the algorithm code (the code has always been ifdef'd out.)
Let's discard it to save some code and memory.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
Cc: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
22 files changed:
drivers/acorn/char/i2c.c
drivers/i2c/algos/i2c-algo-bit.c
drivers/i2c/busses/i2c-hydra.c
drivers/i2c/busses/i2c-i810.c
drivers/i2c/busses/i2c-ixp2000.c
drivers/i2c/busses/i2c-ixp4xx.c
drivers/i2c/busses/i2c-parport-light.c
drivers/i2c/busses/i2c-parport.c
drivers/i2c/busses/i2c-prosavage.c
drivers/i2c/busses/i2c-savage4.c
drivers/i2c/busses/i2c-via.c
drivers/i2c/busses/i2c-voodoo3.c
drivers/i2c/busses/scx200_i2c.c
drivers/ieee1394/pcilynx.c
drivers/media/video/bt8xx/bttv-i2c.c
drivers/media/video/cx88/cx88-i2c.c
drivers/media/video/cx88/cx88-vp3054-i2c.c
drivers/media/video/zoran_card.c
drivers/video/i810/i810-i2c.c
drivers/video/matrox/i2c-matroxfb.c
drivers/video/savage/savagefb-i2c.c
include/linux/i2c-algo-bit.h

index c26c08b368297897f6a07bb86bfb02db3212b3ce..bdb9c8b78ed8afe1a5fd794ce204bef0b60e8d01 100644 (file)
@@ -308,7 +308,6 @@ static struct i2c_algo_bit_data ioc_data = {
        .getsda         = ioc_getsda,
        .getscl         = ioc_getscl,
        .udelay         = 80,
-       .mdelay         = 80,
        .timeout        = 100
 };
 
index ab230c033f9930ce293cf7ae1057db559f60b80e..761df16838b480b8d0fbbed73a2ac09f7f4226a6 100644 (file)
@@ -354,10 +354,6 @@ static int sendbytes(struct i2c_adapter *i2c_adap, struct i2c_msg *msg)
                        return (retval<0)? retval : -EFAULT;
                                /* got a better one ?? */
                }
-#if 0
-               /* from asm/delay.h */
-               __delay(adap->mdelay * (loops_per_sec / 1000) );
-#endif
        }
        return wrcount;
 }
index e0cb3b0f92faba50a64d40f437188f106aaa9c57..457d48a0ab9dcf0c3993917df67ccf924c899cd7 100644 (file)
@@ -99,7 +99,6 @@ static struct i2c_algo_bit_data hydra_bit_data = {
        .getsda         = hydra_bit_getsda,
        .getscl         = hydra_bit_getscl,
        .udelay         = 5,
-       .mdelay         = 5,
        .timeout        = HZ
 };
 
index 748be30f2bae3d740d35914dba90ba72f7b7f3bc..b66fb6bb18700d78068d1ee845ce392c27dce388 100644 (file)
@@ -166,7 +166,6 @@ static struct i2c_algo_bit_data i810_i2c_bit_data = {
        .getsda         = bit_i810i2c_getsda,
        .getscl         = bit_i810i2c_getscl,
        .udelay         = CYCLE_DELAY,
-       .mdelay         = CYCLE_DELAY,
        .timeout        = TIMEOUT,
 };
 
@@ -182,7 +181,6 @@ static struct i2c_algo_bit_data i810_ddc_bit_data = {
        .getsda         = bit_i810ddc_getsda,
        .getscl         = bit_i810ddc_getscl,
        .udelay         = CYCLE_DELAY,
-       .mdelay         = CYCLE_DELAY,
        .timeout        = TIMEOUT,
 };
 
index cd6f45d186ab4d6a3b51ade91cf7bbb8f68a4f3a..dd3f4cd3aa6849cc7945b379705608f18d1f72a2 100644 (file)
@@ -114,7 +114,6 @@ static int ixp2000_i2c_probe(struct platform_device *plat_dev)
        drv_data->algo_data.getsda = ixp2000_bit_getsda;
        drv_data->algo_data.getscl = ixp2000_bit_getscl;
        drv_data->algo_data.udelay = 6;
-       drv_data->algo_data.mdelay = 6;
        drv_data->algo_data.timeout = 100;
 
        drv_data->adapter.id = I2C_HW_B_IXP2000,
index 2ed07112d683fa7cd1c72b0a31a7e95c6645543d..ab573254a8aa305c1703f4005b9477e296819397 100644 (file)
@@ -122,7 +122,6 @@ static int ixp4xx_i2c_probe(struct platform_device *plat_dev)
        drv_data->algo_data.getsda = ixp4xx_bit_getsda;
        drv_data->algo_data.getscl = ixp4xx_bit_getscl;
        drv_data->algo_data.udelay = 10;
-       drv_data->algo_data.mdelay = 10;
        drv_data->algo_data.timeout = 100;
 
        drv_data->adapter.id = I2C_HW_B_IXP4XX;
index e09ebbb2f9f09dc14dc00129211c82cfd4da95cb..5eb2bd294fd97478f78592e26bcb6dd75e027b1e 100644 (file)
@@ -103,7 +103,6 @@ static struct i2c_algo_bit_data parport_algo_data = {
        .getsda         = parport_getsda,
        .getscl         = parport_getscl,
        .udelay         = 50,
-       .mdelay         = 50,
        .timeout        = HZ,
 }; 
 
index 934bd55bae15da1164ca7b14b79a5c7bb2cfcf18..48a829431c7bd1dcdb481776f9dd6e993d3df1c1 100644 (file)
@@ -138,7 +138,6 @@ static struct i2c_algo_bit_data parport_algo_data = {
        .getsda         = parport_getsda,
        .getscl         = parport_getscl,
        .udelay         = 60,
-       .mdelay         = 60,
        .timeout        = HZ,
 }; 
 
index 9479525892e3e337d0872eef7f630041776bf0ff..7745e21874a8e145c8caa5b0a1a9fea44fd32fac 100644 (file)
@@ -180,7 +180,6 @@ static int i2c_register_bus(struct pci_dev *dev, struct s_i2c_bus *p, void __iom
        p->algo.getsda    = bit_s3via_getsda;
        p->algo.getscl    = bit_s3via_getscl;
        p->algo.udelay    = CYCLE_DELAY;
-       p->algo.mdelay    = CYCLE_DELAY;
        p->algo.timeout   = TIMEOUT;
        p->algo.data      = p;
        p->mmvga          = mmvga;
index 0c8518298e4da3da0df6188849c6b3881393dabf..209f47ea175057c7ed3816dd294a4f9d9f6f52a4 100644 (file)
@@ -140,7 +140,6 @@ static struct i2c_algo_bit_data sav_i2c_bit_data = {
        .getsda         = bit_savi2c_getsda,
        .getscl         = bit_savi2c_getscl,
        .udelay         = CYCLE_DELAY,
-       .mdelay         = CYCLE_DELAY,
        .timeout        = TIMEOUT
 };
 
index 484bbacfce6bf005fc435f7f1a653fdc7659495f..910e200ad5001a0ee2e37c2444e0f2c58a3a5595 100644 (file)
@@ -81,7 +81,6 @@ static struct i2c_algo_bit_data bit_data = {
        .getsda         = bit_via_getsda,
        .getscl         = bit_via_getscl,
        .udelay         = 5,
-       .mdelay         = 5,
        .timeout        = HZ
 };
 
index b675773b0cc1d19a9222b87fd319027b4bfef773..6c8d25183382ed7feb150cb72d193b03af4a4f95 100644 (file)
@@ -160,7 +160,6 @@ static struct i2c_algo_bit_data voo_i2c_bit_data = {
        .getsda         = bit_vooi2c_getsda,
        .getscl         = bit_vooi2c_getscl,
        .udelay         = CYCLE_DELAY,
-       .mdelay         = CYCLE_DELAY,
        .timeout        = TIMEOUT
 };
 
@@ -177,7 +176,6 @@ static struct i2c_algo_bit_data voo_ddc_bit_data = {
        .getsda         = bit_vooddc_getsda,
        .getscl         = bit_vooddc_getscl,
        .udelay         = CYCLE_DELAY,
-       .mdelay         = CYCLE_DELAY,
        .timeout        = TIMEOUT
 };
 
index cb3ef5ac99fd06976c0145fd4be0399044f03b90..8b65a5cf8251f1791f389750518529f7e0e69ec6 100644 (file)
@@ -71,12 +71,12 @@ static int scx200_i2c_getsda(void *data)
  */
 
 static struct i2c_algo_bit_data scx200_i2c_data = {
-       NULL,
-       scx200_i2c_setsda,
-       scx200_i2c_setscl,
-       scx200_i2c_getsda,
-       scx200_i2c_getscl,
-       10, 10, 100,            /* waits, timeout */
+       .setsda         = scx200_i2c_setsda,
+       .setscl         = scx200_i2c_setscl,
+       .getsda         = scx200_i2c_getsda,
+       .getscl         = scx200_i2c_getscl,
+       .udelay         = 10,
+       .timeout        = 100,
 };
 
 static struct i2c_adapter scx200_i2c_ops = {
index e6f41238f5e8c6c2f579cb5de5ae1fe0d66ce224..b4f146f2c951c9f7f2f208d8ec972d29e95f77eb 100644 (file)
@@ -137,7 +137,6 @@ static struct i2c_algo_bit_data bit_data = {
        .getsda                 = bit_getsda,
        .getscl                 = bit_getscl,
        .udelay                 = 5,
-       .mdelay                 = 5,
        .timeout                = 100,
 };
 
index 4b562b386fcf6d044882077359763bb2e84ac241..0dfbcc85ebb9d901ba36c53d509da2f794157673 100644 (file)
@@ -100,7 +100,6 @@ static struct i2c_algo_bit_data bttv_i2c_algo_bit_template = {
        .getsda  = bttv_bit_getsda,
        .getscl  = bttv_bit_getscl,
        .udelay  = 16,
-       .mdelay  = 10,
        .timeout = 200,
 };
 
index 70663805cc301234efc682a4901179322b72aa1f..7bea34714861b6e3090f9319bcccfc5d4558c5d1 100644 (file)
@@ -155,7 +155,6 @@ static struct i2c_algo_bit_data cx8800_i2c_algo_template = {
        .getsda  = cx8800_bit_getsda,
        .getscl  = cx8800_bit_getscl,
        .udelay  = 16,
-       .mdelay  = 10,
        .timeout = 200,
 };
 
index 751a754a45e9c02041d29fea98a933516461d100..2b4f1970c7dfec814bf04572de62b14bc75e42e7 100644 (file)
@@ -100,7 +100,6 @@ static struct i2c_algo_bit_data vp3054_i2c_algo_template = {
        .getsda  = vp3054_bit_getsda,
        .getscl  = vp3054_bit_getscl,
        .udelay  = 16,
-       .mdelay  = 10,
        .timeout = 200,
 };
 
index f2249ed25273bc5ded10a920e4891e587faf1c67..29f59c36f0014425ac85efbce2579316ebfff161 100644 (file)
@@ -820,7 +820,6 @@ static struct i2c_algo_bit_data zoran_i2c_bit_data_template = {
        .getsda = zoran_i2c_getsda,
        .getscl = zoran_i2c_getscl,
        .udelay = 10,
-       .mdelay = 0,
        .timeout = 100,
 };
 
index c1f7b49975dd1a8bb78fd1817ddfd33cd3e5018a..7d06b38e80a00f7e4f5d7ead2062a46da7e5730d 100644 (file)
@@ -98,7 +98,6 @@ static int i810_setup_i2c_bus(struct i810fb_i2c_chan *chan, const char *name)
        chan->algo.getsda               = i810i2c_getsda;
        chan->algo.getscl               = i810i2c_getscl;
        chan->algo.udelay               = 10;
-       chan->algo.mdelay               = 10;
         chan->algo.timeout              = (HZ/2);
         chan->algo.data                 = chan;
 
index 9842042d2af596d6bb352e25355d5593f75b6774..795c1a99a680b9f64d3ff84023b811291930b9bc 100644 (file)
@@ -100,7 +100,6 @@ static struct i2c_algo_bit_data matrox_i2c_algo_template =
        .getsda         = matroxfb_gpio_getsda,
        .getscl         = matroxfb_gpio_getscl,
        .udelay         = 10,
-       .mdelay         = 10,
        .timeout        = 100,
 };
 
index e83befd16d634328ddb6029df79aaa3330f1a5a1..d7d810dbf0bdb6b1db553b35529eb99a651a2a25 100644 (file)
@@ -148,7 +148,6 @@ static int savage_setup_i2c_bus(struct savagefb_i2c_chan *chan,
                chan->adapter.algo_data         = &chan->algo;
                chan->adapter.dev.parent        = &chan->par->pcidev->dev;
                chan->algo.udelay               = 40;
-               chan->algo.mdelay               = 5;
                chan->algo.timeout              = 20;
                chan->algo.data                 = chan;
 
index c0e7fab28ce345dc0c48c0a430fc640077caa181..c8f8df25c7e0faa1e19ef06e53bdc4d5442d573c 100644 (file)
@@ -40,7 +40,6 @@ struct i2c_algo_bit_data {
        /* local settings */
        int udelay;             /* half-clock-cycle time in microsecs */
                                /* i.e. clock is (500 / udelay) KHz */
-       int mdelay;             /* in millisecs, unused */
        int timeout;            /* in jiffies */
 };