]> Pileus Git - ~andy/linux/commitdiff
V4L/DVB (7571): mt312: Cleanup buffer variables of read/write functions
authorMatthias Schwarzott <zzam@gentoo.org>
Sat, 12 Apr 2008 18:04:46 +0000 (15:04 -0300)
committerMauro Carvalho Chehab <mchehab@infradead.org>
Thu, 24 Apr 2008 17:09:39 +0000 (14:09 -0300)
Change type of buffer variables from void* to u8* to save some casts.

Signed-off-by: Matthias Schwarzott <zzam@gentoo.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
drivers/media/dvb/frontends/Kconfig
drivers/media/dvb/frontends/Makefile
drivers/media/dvb/frontends/mt312.c

index 0209644f222a803ea677eb585bedc278d50c18ca..4284a3092c14da8f0a49ef28732efc911b571d58 100644 (file)
@@ -369,6 +369,11 @@ config DVB_TUNER_XC5000
          This device is only used inside a SiP called togther with a
          demodulator for now.
 
+config DVB_TUNER_ITD1000
+       tristate "Integrant ITD1000 Zero IF tuner for DVB-S/DSS"
+       depends on DVB_CORE && I2C
+       default m if DVB_FE_CUSTOMISE
+
 comment "Miscellaneous devices"
        depends on DVB_CORE
 
index 23304b3774b5301d2894153651971a76c34e3cdc..129367886bcc4663899c0c428e8b068475bd78c4 100644 (file)
@@ -52,3 +52,4 @@ obj-$(CONFIG_DVB_TUA6100) += tua6100.o
 obj-$(CONFIG_DVB_TUNER_MT2131) += mt2131.o
 obj-$(CONFIG_DVB_S5H1409) += s5h1409.o
 obj-$(CONFIG_DVB_TUNER_XC5000) += xc5000.o
+obj-$(CONFIG_DVB_TUNER_ITD1000) += itd1000.o
index daca855c804a78f05f2c4145ff1dc7a4a5946f80..b03a959ef2e807d1163e9b38c81cb093aed8e46d 100644 (file)
@@ -58,7 +58,7 @@ static int debug;
 #define MT312_PLL_CLK          10000000UL      /* 10 MHz */
 
 static int mt312_read(struct mt312_state *state, const enum mt312_reg_addr reg,
-                     void *buf, const size_t count)
+                     u8 *buf, const size_t count)
 {
        int ret;
        struct i2c_msg msg[2];
@@ -84,7 +84,7 @@ static int mt312_read(struct mt312_state *state, const enum mt312_reg_addr reg,
                int i;
                dprintk("R(%d):", reg & 0x7f);
                for (i = 0; i < count; i++)
-                       printk(" %02x", ((const u8 *) buf)[i]);
+                       printk(" %02x", buf[i]);
                printk("\n");
        }
 
@@ -92,7 +92,7 @@ static int mt312_read(struct mt312_state *state, const enum mt312_reg_addr reg,
 }
 
 static int mt312_write(struct mt312_state *state, const enum mt312_reg_addr reg,
-                      const void *src, const size_t count)
+                      const u8 *src, const size_t count)
 {
        int ret;
        u8 buf[count + 1];
@@ -102,7 +102,7 @@ static int mt312_write(struct mt312_state *state, const enum mt312_reg_addr reg,
                int i;
                dprintk("W(%d):", reg & 0x7f);
                for (i = 0; i < count; i++)
-                       printk(" %02x", ((const u8 *) src)[i]);
+                       printk(" %02x", src[i]);
                printk("\n");
        }
 
@@ -463,7 +463,7 @@ static int mt312_read_snr(struct dvb_frontend *fe, u16 *snr)
        int ret;
        u8 buf[2];
 
-       ret = mt312_read(state, M_SNR_H, &buf, sizeof(buf));
+       ret = mt312_read(state, M_SNR_H, buf, sizeof(buf));
        if (ret < 0)
                return ret;
 
@@ -478,7 +478,7 @@ static int mt312_read_ucblocks(struct dvb_frontend *fe, u32 *ubc)
        int ret;
        u8 buf[2];
 
-       ret = mt312_read(state, RS_UBC_H, &buf, sizeof(buf));
+       ret = mt312_read(state, RS_UBC_H, buf, sizeof(buf));
        if (ret < 0)
                return ret;