diff options
Diffstat (limited to 'linux/drivers/media/dvb/frontends')
-rw-r--r-- | linux/drivers/media/dvb/frontends/alps_bsrv2.c | 57 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/alps_tdlb7.c | 39 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/alps_tdmb7.c | 45 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/at76c651.c | 60 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/cx24110.c | 51 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/dvb_dummy_fe.c | 21 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/grundig_29504-401.c | 39 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/grundig_29504-491.c | 66 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/stv0299.c | 87 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/ves1820.c | 62 |
10 files changed, 177 insertions, 350 deletions
diff --git a/linux/drivers/media/dvb/frontends/alps_bsrv2.c b/linux/drivers/media/dvb/frontends/alps_bsrv2.c index b3b65130e..99ddb460f 100644 --- a/linux/drivers/media/dvb/frontends/alps_bsrv2.c +++ b/linux/drivers/media/dvb/frontends/alps_bsrv2.c @@ -32,8 +32,7 @@ static int debug = 0; #define dprintk if (debug) printk -static -struct dvb_frontend_info bsrv2_info = { +static struct dvb_frontend_info bsrv2_info = { .name = "Alps BSRV2", .type = FE_QPSK, .frequency_min = 950000, @@ -52,8 +51,7 @@ struct dvb_frontend_info bsrv2_info = { -static -u8 init_1893_tab [] = { +static u8 init_1893_tab [] = { 0x01, 0xA4, 0x35, 0x81, 0x2A, 0x0d, 0x55, 0xC4, 0x09, 0x69, 0x00, 0x86, 0x4c, 0x28, 0x7F, 0x00, 0x00, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -64,8 +62,7 @@ u8 init_1893_tab [] = { }; -static -u8 init_1893_wtab[] = +static u8 init_1893_wtab[] = { 1,1,1,1,1,1,1,1, 1,1,0,0,1,1,0,0, 0,1,0,0,0,0,0,0, 1,0,1,1,0,0,0,1, @@ -74,8 +71,7 @@ u8 init_1893_wtab[] = }; -static -int ves1893_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) +static int ves1893_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) { u8 buf [] = { 0x00, reg, data }; struct i2c_msg msg = { .addr = 0x08, .flags = 0, .buf = buf, .len = 3 }; @@ -90,8 +86,7 @@ int ves1893_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) } -static -u8 ves1893_readreg (struct dvb_i2c_bus *i2c, u8 reg) +static u8 ves1893_readreg (struct dvb_i2c_bus *i2c, u8 reg) { int ret; u8 b0 [] = { 0x00, reg }; @@ -108,8 +103,7 @@ u8 ves1893_readreg (struct dvb_i2c_bus *i2c, u8 reg) } -static -int sp5659_write (struct dvb_i2c_bus *i2c, u8 data [4]) +static int sp5659_write (struct dvb_i2c_bus *i2c, u8 data [4]) { int ret; struct i2c_msg msg = { .addr = 0x61, .flags = 0, .buf = data, .len = 4 }; @@ -128,8 +122,7 @@ int sp5659_write (struct dvb_i2c_bus *i2c, u8 data [4]) * set up the downconverter frequency divisor for a * reference clock comparision frequency of 125 kHz. */ -static -int sp5659_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, u8 pwr) +static int sp5659_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, u8 pwr) { u32 div = (freq + 479500) / 125; u8 buf [4] = { (div >> 8) & 0x7f, div & 0xff, 0x95, (pwr << 5) | 0x30 }; @@ -138,8 +131,7 @@ int sp5659_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, u8 pwr) } -static -int ves1893_init (struct dvb_i2c_bus *i2c) +static int ves1893_init (struct dvb_i2c_bus *i2c) { int i; @@ -153,8 +145,7 @@ int ves1893_init (struct dvb_i2c_bus *i2c) } -static -int ves1893_clr_bit (struct dvb_i2c_bus *i2c) +static int ves1893_clr_bit (struct dvb_i2c_bus *i2c) { ves1893_writereg (i2c, 0, init_1893_tab[0] & 0xfe); ves1893_writereg (i2c, 0, init_1893_tab[0]); @@ -163,8 +154,7 @@ int ves1893_clr_bit (struct dvb_i2c_bus *i2c) } -static -int ves1893_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversion) +static int ves1893_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversion) { u8 val; @@ -186,8 +176,7 @@ int ves1893_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inve } -static -int ves1893_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) +static int ves1893_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) { if (fec == FEC_AUTO) return ves1893_writereg (i2c, 0x0d, 0x08); @@ -198,15 +187,13 @@ int ves1893_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) } -static -fe_code_rate_t ves1893_get_fec (struct dvb_i2c_bus *i2c) +static fe_code_rate_t ves1893_get_fec (struct dvb_i2c_bus *i2c) { return FEC_1_2 + ((ves1893_readreg (i2c, 0x0d) >> 4) & 0x7); } -static -int ves1893_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) +static int ves1893_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) { u32 BDR; u32 ratio; @@ -289,8 +276,7 @@ int ves1893_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) } -static -int ves1893_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) +static int ves1893_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) { switch (voltage) { case SEC_VOLTAGE_13: @@ -305,8 +291,7 @@ int ves1893_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) } -static -int bsrv2_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int bsrv2_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { struct dvb_i2c_bus *i2c = fe->i2c; @@ -430,8 +415,7 @@ int bsrv2_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) } -static -int bsrv2_attach (struct dvb_i2c_bus *i2c) +static int bsrv2_attach (struct dvb_i2c_bus *i2c) { if ((ves1893_readreg (i2c, 0x1e) & 0xf0) != 0xd0) return -ENODEV; @@ -442,22 +426,19 @@ int bsrv2_attach (struct dvb_i2c_bus *i2c) } -static -void bsrv2_detach (struct dvb_i2c_bus *i2c) +static void bsrv2_detach (struct dvb_i2c_bus *i2c) { dvb_unregister_frontend (bsrv2_ioctl, i2c); } -static -int __init init_bsrv2 (void) +static int __init init_bsrv2 (void) { return dvb_register_i2c_device (THIS_MODULE, bsrv2_attach, bsrv2_detach); } -static -void __exit exit_bsrv2 (void) +static void __exit exit_bsrv2 (void) { dvb_unregister_i2c_device (bsrv2_attach); } diff --git a/linux/drivers/media/dvb/frontends/alps_tdlb7.c b/linux/drivers/media/dvb/frontends/alps_tdlb7.c index 45677c1e8..d366f5609 100644 --- a/linux/drivers/media/dvb/frontends/alps_tdlb7.c +++ b/linux/drivers/media/dvb/frontends/alps_tdlb7.c @@ -70,8 +70,7 @@ static char * mcfile = "/usr/lib/DVB/driver/frontends/Sc_main.mc"; static int errno; -static -struct dvb_frontend_info tdlb7_info = { +static struct dvb_frontend_info tdlb7_info = { .name = "Alps TDLB7", .type = FE_OFDM, .frequency_min = 470000000, @@ -90,8 +89,7 @@ struct dvb_frontend_info tdlb7_info = { }; -static -int sp8870_writereg (struct dvb_i2c_bus *i2c, u16 reg, u16 data) +static int sp8870_writereg (struct dvb_i2c_bus *i2c, u16 reg, u16 data) { u8 buf [] = { reg >> 8, reg & 0xff, data >> 8, data & 0xff }; struct i2c_msg msg = { .addr = 0x71, .flags = 0, .buf = buf, .len = 4 }; @@ -106,8 +104,7 @@ int sp8870_writereg (struct dvb_i2c_bus *i2c, u16 reg, u16 data) } -static -u16 sp8870_readreg (struct dvb_i2c_bus *i2c, u16 reg) +static u16 sp8870_readreg (struct dvb_i2c_bus *i2c, u16 reg) { int ret; u8 b0 [] = { reg >> 8 , reg & 0xff }; @@ -124,8 +121,7 @@ u16 sp8870_readreg (struct dvb_i2c_bus *i2c, u16 reg) } -static -int sp5659_write (struct dvb_i2c_bus *i2c, u8 data [4]) +static int sp5659_write (struct dvb_i2c_bus *i2c, u8 data [4]) { int ret; struct i2c_msg msg = { .addr = 0x60, .flags = 0, .buf = data, .len = 4 }; @@ -139,8 +135,7 @@ int sp5659_write (struct dvb_i2c_bus *i2c, u8 data [4]) } -static -int sp5659_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) +static int sp5659_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) { u32 div = (freq + 36200000) / 166666; u8 buf [4]; @@ -160,8 +155,7 @@ int sp5659_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) } -static -int sp8870_read_code(const char *fn, char **fp) +static int sp8870_read_code(const char *fn, char **fp) { int fd; loff_t l; @@ -197,8 +191,7 @@ int sp8870_read_code(const char *fn, char **fp) } -static -int sp8870_load_code(struct dvb_i2c_bus *i2c) +static int sp8870_load_code(struct dvb_i2c_bus *i2c) { /* this takes a long time. is there a way to do it faster? */ char *lcode; @@ -245,8 +238,7 @@ int sp8870_load_code(struct dvb_i2c_bus *i2c) }; -static -int sp8870_init (struct dvb_i2c_bus *i2c) +static int sp8870_init (struct dvb_i2c_bus *i2c) { dprintk ("%s\n", __FUNCTION__); @@ -285,8 +277,7 @@ int sp8870_init (struct dvb_i2c_bus *i2c) } -static -int tdlb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int tdlb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { struct dvb_i2c_bus *i2c = fe->i2c; @@ -415,8 +406,7 @@ int tdlb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) } -static -int tdlb7_attach (struct dvb_i2c_bus *i2c) +static int tdlb7_attach (struct dvb_i2c_bus *i2c) { struct i2c_msg msg = { .addr = 0x71, .flags = 0, .buf = NULL, .len = 0 }; @@ -440,8 +430,7 @@ int tdlb7_attach (struct dvb_i2c_bus *i2c) } -static -void tdlb7_detach (struct dvb_i2c_bus *i2c) +static void tdlb7_detach (struct dvb_i2c_bus *i2c) { dprintk ("%s\n", __FUNCTION__); @@ -449,8 +438,7 @@ void tdlb7_detach (struct dvb_i2c_bus *i2c) } -static -int __init init_tdlb7 (void) +static int __init init_tdlb7 (void) { dprintk ("%s\n", __FUNCTION__); @@ -458,8 +446,7 @@ int __init init_tdlb7 (void) } -static -void __exit exit_tdlb7 (void) +static void __exit exit_tdlb7 (void) { dprintk ("%s\n", __FUNCTION__); diff --git a/linux/drivers/media/dvb/frontends/alps_tdmb7.c b/linux/drivers/media/dvb/frontends/alps_tdmb7.c index b5fa11878..175feeb48 100644 --- a/linux/drivers/media/dvb/frontends/alps_tdmb7.c +++ b/linux/drivers/media/dvb/frontends/alps_tdmb7.c @@ -34,8 +34,7 @@ static int debug = 0; #define dprintk if (debug) printk -static -struct dvb_frontend_info tdmb7_info = { +static struct dvb_frontend_info tdmb7_info = { .name = "Alps TDMB7", .type = FE_OFDM, .frequency_min = 470000000, @@ -55,8 +54,7 @@ struct dvb_frontend_info tdmb7_info = { }; -static -u8 init_tab [] = { +static u8 init_tab [] = { 0x04, 0x10, 0x05, 0x09, 0x06, 0x00, @@ -78,8 +76,7 @@ u8 init_tab [] = { }; -static -int cx22700_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) +static int cx22700_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) { int ret; u8 buf [] = { reg, data }; @@ -97,8 +94,7 @@ int cx22700_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) } -static -u8 cx22700_readreg (struct dvb_i2c_bus *i2c, u8 reg) +static u8 cx22700_readreg (struct dvb_i2c_bus *i2c, u8 reg) { int ret; u8 b0 [] = { reg }; @@ -117,8 +113,7 @@ u8 cx22700_readreg (struct dvb_i2c_bus *i2c, u8 reg) } -static -int pll_write (struct dvb_i2c_bus *i2c, u8 data [4]) +static int pll_write (struct dvb_i2c_bus *i2c, u8 data [4]) { struct i2c_msg msg = { .addr = 0x61, .flags = 0, .buf = data, .len = 4 }; int ret; @@ -138,8 +133,7 @@ int pll_write (struct dvb_i2c_bus *i2c, u8 data [4]) * set up the downconverter frequency divisor for a * reference clock comparision frequency of 125 kHz. */ -static -int pll_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) +static int pll_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) { u32 div = (freq + 36166667) / 166667; #if 1 //ALPS_SETTINGS @@ -156,8 +150,7 @@ int pll_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) } -static -int cx22700_init (struct dvb_i2c_bus *i2c) +static int cx22700_init (struct dvb_i2c_bus *i2c) { int i; @@ -177,8 +170,7 @@ int cx22700_init (struct dvb_i2c_bus *i2c) } -static -int cx22700_set_inversion (struct dvb_i2c_bus *i2c, int inversion) +static int cx22700_set_inversion (struct dvb_i2c_bus *i2c, int inversion) { u8 val; @@ -199,8 +191,7 @@ int cx22700_set_inversion (struct dvb_i2c_bus *i2c, int inversion) } -static -int cx22700_set_tps (struct dvb_i2c_bus *i2c, struct dvb_ofdm_parameters *p) +static int cx22700_set_tps (struct dvb_i2c_bus *i2c, struct dvb_ofdm_parameters *p) { static const u8 qam_tab [4] = { 0, 1, 0, 2 }; static const u8 fec_tab [6] = { 0, 1, 2, 0, 3, 4 }; @@ -263,8 +254,7 @@ int cx22700_set_tps (struct dvb_i2c_bus *i2c, struct dvb_ofdm_parameters *p) } -static -int cx22700_get_tps (struct dvb_i2c_bus *i2c, struct dvb_ofdm_parameters *p) +static int cx22700_get_tps (struct dvb_i2c_bus *i2c, struct dvb_ofdm_parameters *p) { static const fe_modulation_t qam_tab [3] = { QPSK, QAM_16, QAM_64 }; static const fe_code_rate_t fec_tab [5] = { FEC_1_2, FEC_2_3, FEC_3_4, @@ -311,8 +301,7 @@ int cx22700_get_tps (struct dvb_i2c_bus *i2c, struct dvb_ofdm_parameters *p) } -static -int tdmb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int tdmb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { struct dvb_i2c_bus *i2c = fe->i2c; @@ -413,8 +402,7 @@ int tdmb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) -static -int tdmb7_attach (struct dvb_i2c_bus *i2c) +static int tdmb7_attach (struct dvb_i2c_bus *i2c) { struct i2c_msg msg = { .addr = 0x43, .flags = 0, .buf = NULL,. len = 0 }; @@ -429,8 +417,7 @@ int tdmb7_attach (struct dvb_i2c_bus *i2c) } -static -void tdmb7_detach (struct dvb_i2c_bus *i2c) +static void tdmb7_detach (struct dvb_i2c_bus *i2c) { dprintk ("%s\n", __FUNCTION__); @@ -438,8 +425,7 @@ void tdmb7_detach (struct dvb_i2c_bus *i2c) } -static -int __init init_tdmb7 (void) +static int __init init_tdmb7 (void) { dprintk ("%s\n", __FUNCTION__); @@ -447,8 +433,7 @@ int __init init_tdmb7 (void) } -static -void __exit exit_tdmb7 (void) +static void __exit exit_tdmb7 (void) { dprintk ("%s\n", __FUNCTION__); diff --git a/linux/drivers/media/dvb/frontends/at76c651.c b/linux/drivers/media/dvb/frontends/at76c651.c index c1b798da2..29ab208a8 100644 --- a/linux/drivers/media/dvb/frontends/at76c651.c +++ b/linux/drivers/media/dvb/frontends/at76c651.c @@ -74,8 +74,7 @@ static struct dvb_frontend_info at76c651_info = { }; #if ! defined(__powerpc__) -static __inline__ int -__ilog2(unsigned long x) +static __inline__ int __ilog2(unsigned long x) { int i; @@ -89,8 +88,7 @@ __ilog2(unsigned long x) } #endif -static int -at76c651_writereg(struct dvb_i2c_bus *i2c, u8 reg, u8 data) +static int at76c651_writereg(struct dvb_i2c_bus *i2c, u8 reg, u8 data) { int ret; @@ -110,8 +108,7 @@ at76c651_writereg(struct dvb_i2c_bus *i2c, u8 reg, u8 data) } -static u8 -at76c651_readreg(struct dvb_i2c_bus *i2c, u8 reg) +static u8 at76c651_readreg(struct dvb_i2c_bus *i2c, u8 reg) { int ret; @@ -129,8 +126,7 @@ at76c651_readreg(struct dvb_i2c_bus *i2c, u8 reg) } -static int -at76c651_set_auto_config(struct dvb_i2c_bus *i2c) +static int at76c651_set_auto_config(struct dvb_i2c_bus *i2c) { at76c651_writereg(i2c, 0x06, 0x01); @@ -149,8 +145,7 @@ at76c651_set_auto_config(struct dvb_i2c_bus *i2c) } -static int -at76c651_set_bbfreq(struct dvb_i2c_bus *i2c) +static int at76c651_set_bbfreq(struct dvb_i2c_bus *i2c) { at76c651_writereg(i2c, 0x04, 0x3f); @@ -160,24 +155,21 @@ at76c651_set_bbfreq(struct dvb_i2c_bus *i2c) } -static int -at76c651_reset(struct dvb_i2c_bus *i2c) +static int at76c651_reset(struct dvb_i2c_bus *i2c) { return at76c651_writereg(i2c, 0x07, 0x01); } -static int -at76c651_disable_interrupts(struct dvb_i2c_bus *i2c) +static int at76c651_disable_interrupts(struct dvb_i2c_bus *i2c) { return at76c651_writereg(i2c, 0x0b, 0x00); } -static int -at76c651_switch_tuner_i2c(struct dvb_i2c_bus *i2c, u8 enable) +static int at76c651_switch_tuner_i2c(struct dvb_i2c_bus *i2c, u8 enable) { if (enable) @@ -187,8 +179,7 @@ at76c651_switch_tuner_i2c(struct dvb_i2c_bus *i2c, u8 enable) } -static int -dat7021_write(struct dvb_i2c_bus *i2c, u32 tw) +static int dat7021_write(struct dvb_i2c_bus *i2c, u32 tw) { int ret; @@ -210,8 +201,7 @@ dat7021_write(struct dvb_i2c_bus *i2c, u32 tw) } -static int -dat7021_set_tv_freq(struct dvb_i2c_bus *i2c, u32 freq) +static int dat7021_set_tv_freq(struct dvb_i2c_bus *i2c, u32 freq) { u32 dw; @@ -239,8 +229,7 @@ dat7021_set_tv_freq(struct dvb_i2c_bus *i2c, u32 freq) } -static int -at76c651_set_symbolrate(struct dvb_i2c_bus *i2c, u32 symbolrate) +static int at76c651_set_symbolrate(struct dvb_i2c_bus *i2c, u32 symbolrate) { u8 exponent; @@ -266,8 +255,7 @@ at76c651_set_symbolrate(struct dvb_i2c_bus *i2c, u32 symbolrate) } -static int -at76c651_set_qam(struct dvb_i2c_bus *i2c, fe_modulation_t qam) +static int at76c651_set_qam(struct dvb_i2c_bus *i2c, fe_modulation_t qam) { u8 qamsel = 0; @@ -309,8 +297,7 @@ at76c651_set_qam(struct dvb_i2c_bus *i2c, fe_modulation_t qam) } -static int -at76c651_set_inversion(struct dvb_i2c_bus *i2c, +static int at76c651_set_inversion(struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversion) { @@ -338,8 +325,7 @@ at76c651_set_inversion(struct dvb_i2c_bus *i2c, } -static int -at76c651_set_parameters(struct dvb_i2c_bus *i2c, +static int at76c651_set_parameters(struct dvb_i2c_bus *i2c, struct dvb_frontend_parameters *p) { @@ -352,8 +338,7 @@ at76c651_set_parameters(struct dvb_i2c_bus *i2c, } -static int -at76c651_set_defaults(struct dvb_i2c_bus *i2c) +static int at76c651_set_defaults(struct dvb_i2c_bus *i2c) { at76c651_set_symbolrate(i2c, 6900000); @@ -366,8 +351,7 @@ at76c651_set_defaults(struct dvb_i2c_bus *i2c) } -static int -at76c651_ioctl(struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int at76c651_ioctl(struct dvb_frontend *fe, unsigned int cmd, void *arg) { switch (cmd) { @@ -463,8 +447,7 @@ at76c651_ioctl(struct dvb_frontend *fe, unsigned int cmd, void *arg) } -static int -at76c651_attach(struct dvb_i2c_bus *i2c) +static int at76c651_attach(struct dvb_i2c_bus *i2c) { if (at76c651_readreg(i2c, 0x0e) != 0x65) { @@ -503,8 +486,7 @@ at76c651_attach(struct dvb_i2c_bus *i2c) } -static void -at76c651_detach(struct dvb_i2c_bus *i2c) +static void at76c651_detach(struct dvb_i2c_bus *i2c) { dvb_unregister_frontend(at76c651_ioctl, i2c); @@ -513,8 +495,7 @@ at76c651_detach(struct dvb_i2c_bus *i2c) } -static int __init -at76c651_init(void) +static int __init at76c651_init(void) { return dvb_register_i2c_device(THIS_MODULE, at76c651_attach, @@ -522,8 +503,7 @@ at76c651_init(void) } -static void __exit -at76c651_exit(void) +static void __exit at76c651_exit(void) { dvb_unregister_i2c_device(at76c651_attach); diff --git a/linux/drivers/media/dvb/frontends/cx24110.c b/linux/drivers/media/dvb/frontends/cx24110.c index 8220ddfe0..fe7571e7e 100644 --- a/linux/drivers/media/dvb/frontends/cx24110.c +++ b/linux/drivers/media/dvb/frontends/cx24110.c @@ -44,8 +44,7 @@ static int debug = 0; #define dprintk if (debug) printk -static -struct dvb_frontend_info cx24110_info = { +static struct dvb_frontend_info cx24110_info = { .name = "Conexant CX24110 with CX24108 tuner, aka HM1221/HM1811", .type = FE_QPSK, .frequency_min = 950000, @@ -66,8 +65,7 @@ struct dvb_frontend_info cx24110_info = { /* fixme: are these values correct? especially ..._tolerance and caps */ -static -struct {u8 reg; u8 data;} cx24110_regdata[]= +static struct {u8 reg; u8 data;} cx24110_regdata[]= /* Comments beginning with @ denote this value should be the default */ {{0x09,0x01}, /* SoftResetAll */ @@ -130,8 +128,7 @@ struct {u8 reg; u8 data;} cx24110_regdata[]= }; -static -int cx24110_writereg (struct dvb_i2c_bus *i2c, int reg, int data) +static int cx24110_writereg (struct dvb_i2c_bus *i2c, int reg, int data) { u8 buf [] = { reg, data }; struct i2c_msg msg = { .addr = 0x55, .flags = 0, .buf = buf, .len = 2 }; @@ -148,8 +145,7 @@ int cx24110_writereg (struct dvb_i2c_bus *i2c, int reg, int data) } -static -u8 cx24110_readreg (struct dvb_i2c_bus *i2c, u8 reg) +static u8 cx24110_readreg (struct dvb_i2c_bus *i2c, u8 reg) { int ret; u8 b0 [] = { reg }; @@ -166,8 +162,7 @@ u8 cx24110_readreg (struct dvb_i2c_bus *i2c, u8 reg) } -static -int cx24108_write (struct dvb_i2c_bus *i2c, u32 data) +static int cx24108_write (struct dvb_i2c_bus *i2c, u32 data) { /* tuner data is 21 bits long, must be left-aligned in data */ /* tuner cx24108 is written through a dedicated 3wire interface on the demod chip */ @@ -201,8 +196,7 @@ dprintk("cx24110 debug: cx24108_write(%8.8x)\n",data); } -static -int cx24108_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) +static int cx24108_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) { /* fixme (low): error handling */ int i, a, n, pump; @@ -266,8 +260,7 @@ int cx24108_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) } -static -int cx24110_init (struct dvb_i2c_bus *i2c) +static int cx24110_init (struct dvb_i2c_bus *i2c) { /* fixme (low): error handling */ int i; @@ -282,8 +275,7 @@ int cx24110_init (struct dvb_i2c_bus *i2c) } -static -int cx24110_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversion) +static int cx24110_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversion) { /* fixme (low): error handling */ @@ -318,8 +310,7 @@ int cx24110_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inve } -static -int cx24110_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) +static int cx24110_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) { /* fixme (low): error handling */ @@ -365,8 +356,7 @@ int cx24110_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) } -static -fe_code_rate_t cx24110_get_fec (struct dvb_i2c_bus *i2c) +static fe_code_rate_t cx24110_get_fec (struct dvb_i2c_bus *i2c) { int i; @@ -383,8 +373,7 @@ fe_code_rate_t cx24110_get_fec (struct dvb_i2c_bus *i2c) } -static -int cx24110_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) +static int cx24110_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) { /* fixme (low): add error handling */ u32 ratio; @@ -466,8 +455,7 @@ dprintk("cx24110 debug: entering %s(%d)\n",__FUNCTION__,srate); } -static -int cx24110_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) +static int cx24110_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) { switch (voltage) { case SEC_VOLTAGE_13: @@ -494,8 +482,7 @@ static void sendDiSEqCMessage(struct dvb_i2c_bus *i2c, struct dvb_diseqc_master_ } -static -int cx24110_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int cx24110_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { struct dvb_i2c_bus *i2c = fe->i2c; static int lastber=0, lastbyer=0,lastbler=0, lastesn0=0, sum_bler=0; @@ -656,8 +643,7 @@ int cx24110_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) } -static -int cx24110_attach (struct dvb_i2c_bus *i2c) +static int cx24110_attach (struct dvb_i2c_bus *i2c) { u8 sig; @@ -671,22 +657,19 @@ int cx24110_attach (struct dvb_i2c_bus *i2c) } -static -void cx24110_detach (struct dvb_i2c_bus *i2c) +static void cx24110_detach (struct dvb_i2c_bus *i2c) { dvb_unregister_frontend (cx24110_ioctl, i2c); } -static -int __init init_cx24110 (void) +static int __init init_cx24110 (void) { return dvb_register_i2c_device (THIS_MODULE, cx24110_attach, cx24110_detach); } -static -void __exit exit_cx24110 (void) +static void __exit exit_cx24110 (void) { dvb_unregister_i2c_device (cx24110_attach); } diff --git a/linux/drivers/media/dvb/frontends/dvb_dummy_fe.c b/linux/drivers/media/dvb/frontends/dvb_dummy_fe.c index 984e089ce..6966f8542 100644 --- a/linux/drivers/media/dvb/frontends/dvb_dummy_fe.c +++ b/linux/drivers/media/dvb/frontends/dvb_dummy_fe.c @@ -30,8 +30,7 @@ static int sct = 0; /* depending on module parameter sct deliver different infos */ -static -struct dvb_frontend_info dvb_s_dummyfe_info = { +static struct dvb_frontend_info dvb_s_dummyfe_info = { .name = "DVB-S dummy frontend", .type = FE_QPSK, .frequency_min = 950000, @@ -48,8 +47,7 @@ struct dvb_frontend_info dvb_s_dummyfe_info = { FE_CAN_QPSK }; -static -struct dvb_frontend_info dvb_c_dummyfe_info = { +static struct dvb_frontend_info dvb_c_dummyfe_info = { .name = "DVB-C dummy frontend", .type = FE_QAM, .frequency_stepsize = 62500, @@ -103,8 +101,7 @@ struct dvb_frontend_info *frontend_info(void) } -static -int dvbdummyfe_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int dvbdummyfe_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { switch (cmd) { case FE_GET_INFO: @@ -176,23 +173,20 @@ int dvbdummyfe_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) } -static -int dvbdummyfe_attach (struct dvb_i2c_bus *i2c) +static int dvbdummyfe_attach (struct dvb_i2c_bus *i2c) { dvb_register_frontend (dvbdummyfe_ioctl, i2c, NULL, frontend_info()); return 0; } -static -void dvbdummyfe_detach (struct dvb_i2c_bus *i2c) +static void dvbdummyfe_detach (struct dvb_i2c_bus *i2c) { dvb_unregister_frontend (dvbdummyfe_ioctl, i2c); } -static -int __init init_dvbdummyfe (void) +static int __init init_dvbdummyfe (void) { return dvb_register_i2c_device (THIS_MODULE, dvbdummyfe_attach, @@ -201,8 +195,7 @@ int __init init_dvbdummyfe (void) } -static -void __exit exit_dvbdummyfe (void) +static void __exit exit_dvbdummyfe (void) { dvb_unregister_i2c_device (dvbdummyfe_attach); return; diff --git a/linux/drivers/media/dvb/frontends/grundig_29504-401.c b/linux/drivers/media/dvb/frontends/grundig_29504-401.c index d4cbcf8ff..1bcf02289 100644 --- a/linux/drivers/media/dvb/frontends/grundig_29504-401.c +++ b/linux/drivers/media/dvb/frontends/grundig_29504-401.c @@ -52,8 +52,7 @@ struct dvb_frontend_info grundig_29504_401_info = { }; -static -int l64781_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) +static int l64781_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) { int ret; u8 buf [] = { reg, data }; @@ -67,8 +66,7 @@ int l64781_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) } -static -u8 l64781_readreg (struct dvb_i2c_bus *i2c, u8 reg) +static u8 l64781_readreg (struct dvb_i2c_bus *i2c, u8 reg) { int ret; u8 b0 [] = { reg }; @@ -85,8 +83,7 @@ u8 l64781_readreg (struct dvb_i2c_bus *i2c, u8 reg) } -static -int tsa5060_write (struct dvb_i2c_bus *i2c, u8 data [4]) +static int tsa5060_write (struct dvb_i2c_bus *i2c, u8 data [4]) { int ret; struct i2c_msg msg = { .addr = 0x61, .flags = 0, .buf = data, .len = 4 }; @@ -103,8 +100,7 @@ int tsa5060_write (struct dvb_i2c_bus *i2c, u8 data [4]) * reference clock comparision frequency of 166666 Hz. * frequency offset is 36125000 Hz. */ -static -int tsa5060_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) +static int tsa5060_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) { u32 div; u8 buf [4]; @@ -128,8 +124,7 @@ int tsa5060_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) -static -void apply_tps (struct dvb_i2c_bus *i2c) +static void apply_tps (struct dvb_i2c_bus *i2c) { l64781_writereg (i2c, 0x2a, 0x00); l64781_writereg (i2c, 0x2a, 0x01); @@ -143,8 +138,7 @@ void apply_tps (struct dvb_i2c_bus *i2c) } -static -void reset_afc (struct dvb_i2c_bus *i2c) +static void reset_afc (struct dvb_i2c_bus *i2c) { /* Set AFC stall for the AFC_INIT_FRQ setting, TIM_STALL for timing offset */ @@ -162,8 +156,7 @@ void reset_afc (struct dvb_i2c_bus *i2c) } -static -int apply_frontend_param (struct dvb_i2c_bus *i2c, +static int apply_frontend_param (struct dvb_i2c_bus *i2c, struct dvb_frontend_parameters *param) { /* The coderates for FEC_NONE, FEC_4_5 and FEC_FEC_6_7 are arbitrary */ @@ -275,8 +268,7 @@ int apply_frontend_param (struct dvb_i2c_bus *i2c, } -static -int reset_and_configure (struct dvb_i2c_bus *i2c) +static int reset_and_configure (struct dvb_i2c_bus *i2c) { u8 buf [] = { 0x06 }; struct i2c_msg msg = { .addr = 0x00, .flags = 0, .buf = buf, .len = 1 }; @@ -286,8 +278,7 @@ int reset_and_configure (struct dvb_i2c_bus *i2c) -static -int init (struct dvb_i2c_bus *i2c) +static int init (struct dvb_i2c_bus *i2c) { reset_and_configure (i2c); @@ -425,8 +416,7 @@ int grundig_29504_401_ioctl (struct dvb_frontend *fe, } -static -int l64781_attach (struct dvb_i2c_bus *i2c) +static int l64781_attach (struct dvb_i2c_bus *i2c) { u8 reg0x3e; u8 b0 [] = { 0x1a }; @@ -487,23 +477,20 @@ int l64781_attach (struct dvb_i2c_bus *i2c) -static -void l64781_detach (struct dvb_i2c_bus *i2c) +static void l64781_detach (struct dvb_i2c_bus *i2c) { dvb_unregister_frontend (grundig_29504_401_ioctl, i2c); } -static -int __init init_grundig_29504_401 (void) +static int __init init_grundig_29504_401 (void) { return dvb_register_i2c_device (THIS_MODULE, l64781_attach, l64781_detach); } -static -void __exit exit_grundig_29504_401 (void) +static void __exit exit_grundig_29504_401 (void) { dvb_unregister_i2c_device (l64781_attach); } diff --git a/linux/drivers/media/dvb/frontends/grundig_29504-491.c b/linux/drivers/media/dvb/frontends/grundig_29504-491.c index 38e13f765..121a5311f 100644 --- a/linux/drivers/media/dvb/frontends/grundig_29504-491.c +++ b/linux/drivers/media/dvb/frontends/grundig_29504-491.c @@ -37,8 +37,7 @@ static int debug = 0; #define dprintk if (debug) printk -static -struct dvb_frontend_info grundig_29504_491_info = { +static struct dvb_frontend_info grundig_29504_491_info = { .name = "Grundig 29504-491, (TDA8083 based)", .type = FE_QPSK, .frequency_min = 950000, /* FIXME: guessed! */ @@ -59,8 +58,7 @@ struct dvb_frontend_info grundig_29504_491_info = { -static -u8 tda8083_init_tab [] = { +static u8 tda8083_init_tab [] = { 0x04, 0x00, 0x4a, 0x79, 0x04, 0x00, 0xff, 0xea, 0x48, 0x42, 0x79, 0x60, 0x70, 0x52, 0x9a, 0x10, 0x0e, 0x10, 0xf2, 0xa7, 0x93, 0x0b, 0x05, 0xc8, @@ -71,8 +69,7 @@ u8 tda8083_init_tab [] = { -static -int tda8083_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) +static int tda8083_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) { int ret; u8 buf [] = { reg, data }; @@ -88,8 +85,7 @@ int tda8083_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) } -static -int tda8083_readregs (struct dvb_i2c_bus *i2c, u8 reg1, u8 *b, u8 len) +static int tda8083_readregs (struct dvb_i2c_bus *i2c, u8 reg1, u8 *b, u8 len) { int ret; struct i2c_msg msg [] = { { .addr = 0x68, .flags = 0, .buf = ®1, .len = 1 }, @@ -105,8 +101,7 @@ int tda8083_readregs (struct dvb_i2c_bus *i2c, u8 reg1, u8 *b, u8 len) } -static inline -u8 tda8083_readreg (struct dvb_i2c_bus *i2c, u8 reg) +static inline u8 tda8083_readreg (struct dvb_i2c_bus *i2c, u8 reg) { u8 val; @@ -116,8 +111,7 @@ u8 tda8083_readreg (struct dvb_i2c_bus *i2c, u8 reg) } -static -int tsa5522_write (struct dvb_i2c_bus *i2c, u8 data [4]) +static int tsa5522_write (struct dvb_i2c_bus *i2c, u8 data [4]) { int ret; struct i2c_msg msg = { .addr = 0x61, .flags = 0, .buf = data, .len = 4 }; @@ -135,8 +129,7 @@ int tsa5522_write (struct dvb_i2c_bus *i2c, u8 data [4]) * set up the downconverter frequency divisor for a * reference clock comparision frequency of 125 kHz. */ -static -int tsa5522_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) +static int tsa5522_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) { u32 div = freq / 125; u8 buf [4] = { (div >> 8) & 0x7f, div & 0xff, 0x8e, 0x00 }; @@ -145,8 +138,7 @@ int tsa5522_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq) } -static int -tda8083_init (struct dvb_i2c_bus *i2c) +static int tda8083_init (struct dvb_i2c_bus *i2c) { int i; @@ -159,8 +151,7 @@ tda8083_init (struct dvb_i2c_bus *i2c) } -static int -tda8083_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversion) +static int tda8083_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversion) { /* XXX FIXME: implement other modes than FEC_AUTO */ if (inversion == INVERSION_AUTO) @@ -170,8 +161,7 @@ tda8083_set_inversion (struct dvb_i2c_bus *i2c, fe_spectral_inversion_t inversio } -static int -tda8083_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) +static int tda8083_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) { if (fec == FEC_AUTO) return tda8083_writereg (i2c, 0x07, 0xff); @@ -183,8 +173,7 @@ tda8083_set_fec (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) } -static -fe_code_rate_t tda8083_get_fec (struct dvb_i2c_bus *i2c) +static fe_code_rate_t tda8083_get_fec (struct dvb_i2c_bus *i2c) { u8 index; static fe_code_rate_t fec_tab [] = { FEC_8_9, FEC_1_2, FEC_2_3, FEC_3_4, @@ -199,8 +188,7 @@ fe_code_rate_t tda8083_get_fec (struct dvb_i2c_bus *i2c) } -static -int tda8083_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) +static int tda8083_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) { u32 ratio; u32 tmp; @@ -240,8 +228,7 @@ int tda8083_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) } -static -void tda8083_wait_diseqc_fifo (struct dvb_i2c_bus *i2c, int timeout) +static void tda8083_wait_diseqc_fifo (struct dvb_i2c_bus *i2c, int timeout) { unsigned long start = jiffies; @@ -253,8 +240,7 @@ void tda8083_wait_diseqc_fifo (struct dvb_i2c_bus *i2c, int timeout) } -static -int tda8083_send_diseqc_msg (struct dvb_i2c_bus *i2c, +static int tda8083_send_diseqc_msg (struct dvb_i2c_bus *i2c, struct dvb_diseqc_master_cmd *m) { int i; @@ -272,8 +258,7 @@ int tda8083_send_diseqc_msg (struct dvb_i2c_bus *i2c, } -static -int tda8083_send_diseqc_burst (struct dvb_i2c_bus *i2c, fe_sec_mini_cmd_t burst) +static int tda8083_send_diseqc_burst (struct dvb_i2c_bus *i2c, fe_sec_mini_cmd_t burst) { switch (burst) { case SEC_MINI_A: @@ -292,8 +277,7 @@ int tda8083_send_diseqc_burst (struct dvb_i2c_bus *i2c, fe_sec_mini_cmd_t burst) } -static -int tda8083_set_tone (struct dvb_i2c_bus *i2c, fe_sec_tone_mode_t tone) +static int tda8083_set_tone (struct dvb_i2c_bus *i2c, fe_sec_tone_mode_t tone) { tda8083_writereg (i2c, 0x26, 0xf1); @@ -308,8 +292,7 @@ int tda8083_set_tone (struct dvb_i2c_bus *i2c, fe_sec_tone_mode_t tone) } -static -int tda8083_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) +static int tda8083_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) { switch (voltage) { case SEC_VOLTAGE_13: @@ -322,8 +305,7 @@ int tda8083_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) } -static -int grundig_29504_491_ioctl (struct dvb_frontend *fe, unsigned int cmd, +static int grundig_29504_491_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { struct dvb_i2c_bus *i2c = fe->i2c; @@ -454,8 +436,7 @@ int grundig_29504_491_ioctl (struct dvb_frontend *fe, unsigned int cmd, } -static -int tda8083_attach (struct dvb_i2c_bus *i2c) +static int tda8083_attach (struct dvb_i2c_bus *i2c) { if ((tda8083_readreg (i2c, 0x00)) != 0x05) return -ENODEV; @@ -467,23 +448,20 @@ int tda8083_attach (struct dvb_i2c_bus *i2c) } -static -void tda8083_detach (struct dvb_i2c_bus *i2c) +static void tda8083_detach (struct dvb_i2c_bus *i2c) { dvb_unregister_frontend (grundig_29504_491_ioctl, i2c); } -static -int __init init_tda8083 (void) +static int __init init_tda8083 (void) { return dvb_register_i2c_device (THIS_MODULE, tda8083_attach, tda8083_detach); } -static -void __exit exit_tda8083 (void) +static void __exit exit_tda8083 (void) { dvb_unregister_i2c_device (tda8083_attach); } diff --git a/linux/drivers/media/dvb/frontends/stv0299.c b/linux/drivers/media/dvb/frontends/stv0299.c index 60d49a788..1ea653527 100644 --- a/linux/drivers/media/dvb/frontends/stv0299.c +++ b/linux/drivers/media/dvb/frontends/stv0299.c @@ -60,8 +60,7 @@ /* Master Clock = 88 MHz */ #define M_CLK (88000000UL) -static -struct dvb_frontend_info uni0299_info = { +static struct dvb_frontend_info uni0299_info = { .name = "STV0299/TSA5059/SL1935 based", .type = FE_QPSK, .frequency_min = 950000, @@ -80,8 +79,7 @@ struct dvb_frontend_info uni0299_info = { }; -static -u8 init_tab [] = { +static u8 init_tab [] = { 0x04, 0x7d, /* F22FR = 0x7d */ /* F22 = f_VCO / 128 / 0x7d = 22 kHz */ @@ -144,8 +142,7 @@ u8 init_tab [] = { }; -static -int stv0299_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) +static int stv0299_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) { int ret; u8 buf [] = { reg, data }; @@ -161,8 +158,7 @@ int stv0299_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data) } -static -u8 stv0299_readreg (struct dvb_i2c_bus *i2c, u8 reg) +static u8 stv0299_readreg (struct dvb_i2c_bus *i2c, u8 reg) { int ret; u8 b0 [] = { reg }; @@ -179,8 +175,7 @@ u8 stv0299_readreg (struct dvb_i2c_bus *i2c, u8 reg) } -static -int stv0299_readregs (struct dvb_i2c_bus *i2c, u8 reg1, u8 *b, u8 len) +static int stv0299_readregs (struct dvb_i2c_bus *i2c, u8 reg1, u8 *b, u8 len) { int ret; struct i2c_msg msg [] = { { .addr = 0x68, .flags = 0, .buf = ®1, .len = 1 }, @@ -195,8 +190,7 @@ int stv0299_readregs (struct dvb_i2c_bus *i2c, u8 reg1, u8 *b, u8 len) } -static -int pll_write (struct dvb_i2c_bus *i2c, u8 addr, u8 *data, int len) +static int pll_write (struct dvb_i2c_bus *i2c, u8 addr, u8 *data, int len) { int ret; u8 rpt1 [] = { 0x05, 0xb5 }; /* enable i2c repeater on stv0299 */ @@ -214,8 +208,7 @@ int pll_write (struct dvb_i2c_bus *i2c, u8 addr, u8 *data, int len) } -static -int sl1935_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype) +static int sl1935_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype) { u8 buf[4]; u32 div; @@ -245,8 +238,7 @@ int sl1935_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype) * set up the downconverter frequency divisor for a * reference clock comparision frequency of 125 kHz. */ -static -int tsa5059_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype) +static int tsa5059_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype) { u8 addr = (ftype == PHILIPS_SU1278SH) ? 0x60 : 0x61; u32 div = freq / 125; @@ -270,8 +262,7 @@ int tsa5059_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype) #define MIN2(a,b) ((a) < (b) ? (a) : (b)) #define MIN3(a,b,c) MIN2(MIN2(a,b),c) -static -int tua6100_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, +static int tua6100_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype, int srate) { u8 reg0 [2] = { 0x00, 0x00 }; @@ -392,8 +383,7 @@ int tua6100_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, } -static -int pll_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype, int srate) +static int pll_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype, int srate) { if (ftype == LG_TDQF_S001F) return sl1935_set_tv_freq(i2c, freq, ftype); @@ -404,8 +394,7 @@ int pll_set_tv_freq (struct dvb_i2c_bus *i2c, u32 freq, int ftype, int srate) } #if 0 -static -int tsa5059_read_status (struct dvb_i2c_bus *i2c) +static int tsa5059_read_status (struct dvb_i2c_bus *i2c) { int ret; u8 rpt1 [] = { 0x05, 0xb5 }; @@ -426,8 +415,7 @@ int tsa5059_read_status (struct dvb_i2c_bus *i2c) #endif -static -int stv0299_init (struct dvb_i2c_bus *i2c, int ftype) +static int stv0299_init (struct dvb_i2c_bus *i2c, int ftype) { int i; @@ -452,8 +440,7 @@ int stv0299_init (struct dvb_i2c_bus *i2c, int ftype) } -static -int stv0299_check_inversion (struct dvb_i2c_bus *i2c) +static int stv0299_check_inversion (struct dvb_i2c_bus *i2c) { dprintk ("%s\n", __FUNCTION__); @@ -469,8 +456,7 @@ int stv0299_check_inversion (struct dvb_i2c_bus *i2c) } -static -int stv0299_set_FEC (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) +static int stv0299_set_FEC (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) { dprintk ("%s\n", __FUNCTION__); @@ -493,8 +479,7 @@ int stv0299_set_FEC (struct dvb_i2c_bus *i2c, fe_code_rate_t fec) } -static -fe_code_rate_t stv0299_get_fec (struct dvb_i2c_bus *i2c) +static fe_code_rate_t stv0299_get_fec (struct dvb_i2c_bus *i2c) { static fe_code_rate_t fec_tab [] = { FEC_2_3, FEC_3_4, FEC_5_6, FEC_7_8, FEC_1_2 }; @@ -512,8 +497,7 @@ fe_code_rate_t stv0299_get_fec (struct dvb_i2c_bus *i2c) } -static -int stv0299_wait_diseqc_fifo (struct dvb_i2c_bus *i2c, int timeout) +static int stv0299_wait_diseqc_fifo (struct dvb_i2c_bus *i2c, int timeout) { unsigned long start = jiffies; @@ -531,8 +515,7 @@ int stv0299_wait_diseqc_fifo (struct dvb_i2c_bus *i2c, int timeout) } -static -int stv0299_wait_diseqc_idle (struct dvb_i2c_bus *i2c, int timeout) +static int stv0299_wait_diseqc_idle (struct dvb_i2c_bus *i2c, int timeout) { unsigned long start = jiffies; @@ -550,8 +533,7 @@ int stv0299_wait_diseqc_idle (struct dvb_i2c_bus *i2c, int timeout) } -static -int stv0299_send_diseqc_msg (struct dvb_i2c_bus *i2c, +static int stv0299_send_diseqc_msg (struct dvb_i2c_bus *i2c, struct dvb_diseqc_master_cmd *m) { u8 val; @@ -582,8 +564,7 @@ int stv0299_send_diseqc_msg (struct dvb_i2c_bus *i2c, } -static -int stv0299_send_diseqc_burst (struct dvb_i2c_bus *i2c, fe_sec_mini_cmd_t burst) +static int stv0299_send_diseqc_burst (struct dvb_i2c_bus *i2c, fe_sec_mini_cmd_t burst) { u8 val; @@ -610,8 +591,7 @@ int stv0299_send_diseqc_burst (struct dvb_i2c_bus *i2c, fe_sec_mini_cmd_t burst) } -static -int stv0299_set_tone (struct dvb_i2c_bus *i2c, fe_sec_tone_mode_t tone) +static int stv0299_set_tone (struct dvb_i2c_bus *i2c, fe_sec_tone_mode_t tone) { u8 val; @@ -635,8 +615,7 @@ int stv0299_set_tone (struct dvb_i2c_bus *i2c, fe_sec_tone_mode_t tone) } -static -int stv0299_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) +static int stv0299_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) { u8 reg0x08; u8 reg0x0c; @@ -672,8 +651,7 @@ int stv0299_set_voltage (struct dvb_i2c_bus *i2c, fe_sec_voltage_t voltage) } -static -int stv0299_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) +static int stv0299_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) { u32 ratio; u32 tmp; @@ -711,8 +689,7 @@ int stv0299_set_symbolrate (struct dvb_i2c_bus *i2c, u32 srate) } -static -int stv0299_get_symbolrate (struct dvb_i2c_bus *i2c) +static int stv0299_get_symbolrate (struct dvb_i2c_bus *i2c) { u32 Mclk = M_CLK / 4096L; u32 srate; @@ -743,8 +720,7 @@ int stv0299_get_symbolrate (struct dvb_i2c_bus *i2c) } -static -int uni0299_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int uni0299_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { int tuner_type = (long) fe->data; struct dvb_i2c_bus *i2c = fe->i2c; @@ -881,8 +857,7 @@ int uni0299_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) return 0; } -static -long probe_tuner (struct dvb_i2c_bus *i2c) +static long probe_tuner (struct dvb_i2c_bus *i2c) { /* read the status register of TSA5059 */ u8 rpt[] = { 0x05, 0xb5 }; @@ -935,8 +910,7 @@ long probe_tuner (struct dvb_i2c_bus *i2c) } -static -int uni0299_attach (struct dvb_i2c_bus *i2c) +static int uni0299_attach (struct dvb_i2c_bus *i2c) { long tuner_type; u8 id = stv0299_readreg (i2c, 0x00); @@ -958,24 +932,21 @@ int uni0299_attach (struct dvb_i2c_bus *i2c) } -static -void uni0299_detach (struct dvb_i2c_bus *i2c) +static void uni0299_detach (struct dvb_i2c_bus *i2c) { dprintk ("%s\n", __FUNCTION__); dvb_unregister_frontend (uni0299_ioctl, i2c); } -static -int __init init_uni0299 (void) +static int __init init_uni0299 (void) { dprintk ("%s\n", __FUNCTION__); return dvb_register_i2c_device (NULL, uni0299_attach, uni0299_detach); } -static -void __exit exit_uni0299 (void) +static void __exit exit_uni0299 (void) { dprintk ("%s\n", __FUNCTION__); dvb_unregister_i2c_device (uni0299_attach); diff --git a/linux/drivers/media/dvb/frontends/ves1820.c b/linux/drivers/media/dvb/frontends/ves1820.c index e063f207a..025978ce9 100644 --- a/linux/drivers/media/dvb/frontends/ves1820.c +++ b/linux/drivers/media/dvb/frontends/ves1820.c @@ -72,8 +72,7 @@ -static -struct dvb_frontend_info ves1820_info = { +static struct dvb_frontend_info ves1820_info = { .name = "VES1820 based DVB-C frontend", .type = FE_QAM, .frequency_stepsize = 62500, @@ -94,8 +93,7 @@ struct dvb_frontend_info ves1820_info = { -static -u8 ves1820_inittab [] = +static u8 ves1820_inittab [] = { 0x69, 0x6A, 0x9B, 0x0A, 0x52, 0x46, 0x26, 0x1A, 0x43, 0x6A, 0xAA, 0xAA, 0x1E, 0x85, 0x43, 0x28, @@ -107,8 +105,7 @@ u8 ves1820_inittab [] = }; -static -int ves1820_writereg (struct dvb_frontend *fe, u8 reg, u8 data) +static int ves1820_writereg (struct dvb_frontend *fe, u8 reg, u8 data) { u8 addr = GET_DEMOD_ADDR(fe->data); u8 buf[] = { 0x00, reg, data }; @@ -128,8 +125,7 @@ int ves1820_writereg (struct dvb_frontend *fe, u8 reg, u8 data) } -static -u8 ves1820_readreg (struct dvb_frontend *fe, u8 reg) +static u8 ves1820_readreg (struct dvb_frontend *fe, u8 reg) { u8 b0 [] = { 0x00, reg }; u8 b1 [] = { 0 }; @@ -148,8 +144,7 @@ u8 ves1820_readreg (struct dvb_frontend *fe, u8 reg) } -static -int tuner_write (struct dvb_i2c_bus *i2c, u8 addr, u8 data [4]) +static int tuner_write (struct dvb_i2c_bus *i2c, u8 addr, u8 data [4]) { int ret; struct i2c_msg msg = { .addr = addr, .flags = 0, .buf = data, .len = 4 }; @@ -167,8 +162,7 @@ int tuner_write (struct dvb_i2c_bus *i2c, u8 addr, u8 data [4]) * set up the downconverter frequency divisor for a * reference clock comparision frequency of 62.5 kHz. */ -static -int tuner_set_tv_freq (struct dvb_frontend *fe, u32 freq) +static int tuner_set_tv_freq (struct dvb_frontend *fe, u32 freq) { u32 div, ifreq; static u8 addr [] = { 0x61, 0x62 }; @@ -203,8 +197,7 @@ int tuner_set_tv_freq (struct dvb_frontend *fe, u32 freq) } -static -int ves1820_setup_reg0 (struct dvb_frontend *fe, u8 reg0, +static int ves1820_setup_reg0 (struct dvb_frontend *fe, u8 reg0, fe_spectral_inversion_t inversion) { reg0 |= GET_REG0(fe->data) & 0x62; @@ -235,8 +228,7 @@ int ves1820_setup_reg0 (struct dvb_frontend *fe, u8 reg0, } -static -int ves1820_init (struct dvb_frontend *fe) +static int ves1820_init (struct dvb_frontend *fe) { int i; @@ -253,8 +245,7 @@ int ves1820_init (struct dvb_frontend *fe) } -static -int ves1820_set_symbolrate (struct dvb_frontend *fe, u32 symbolrate) +static int ves1820_set_symbolrate (struct dvb_frontend *fe, u32 symbolrate) { s32 BDR; s32 BDRI; @@ -309,8 +300,7 @@ int ves1820_set_symbolrate (struct dvb_frontend *fe, u32 symbolrate) } -static -int ves1820_set_parameters (struct dvb_frontend *fe, +static int ves1820_set_parameters (struct dvb_frontend *fe, struct dvb_frontend_parameters *p) { static const u8 reg0x00 [] = { 0x00, 0x04, 0x08, 0x0c, 0x10 }; @@ -339,8 +329,7 @@ int ves1820_set_parameters (struct dvb_frontend *fe, -static -int ves1820_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) +static int ves1820_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) { switch (cmd) { case FE_GET_INFO: @@ -450,13 +439,12 @@ int ves1820_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg) } -static -long probe_tuner (struct dvb_i2c_bus *i2c) +static long probe_tuner (struct dvb_i2c_bus *i2c) { - static const - struct i2c_msg msg1 = { .addr = 0x61, .flags = 0, .buf = NULL, .len = 0 }; - static const - struct i2c_msg msg2 = { .addr = 0x62, .flags = 0, .buf = NULL, .len = 0 }; + static const struct i2c_msg msg1 = + { .addr = 0x61, .flags = 0, .buf = NULL, .len = 0 }; + static const struct i2c_msg msg2 = + { .addr = 0x62, .flags = 0, .buf = NULL, .len = 0 }; int type; if (i2c->xfer(i2c, &msg1, 1) == 1) { @@ -476,8 +464,7 @@ long probe_tuner (struct dvb_i2c_bus *i2c) } -static -u8 read_pwm (struct dvb_i2c_bus *i2c) +static u8 read_pwm (struct dvb_i2c_bus *i2c) { u8 b = 0xff; u8 pwm; @@ -495,8 +482,7 @@ u8 read_pwm (struct dvb_i2c_bus *i2c) } -static -long probe_demod_addr (struct dvb_i2c_bus *i2c) +static long probe_demod_addr (struct dvb_i2c_bus *i2c) { u8 b [] = { 0x00, 0x1a }; u8 id; @@ -515,8 +501,7 @@ long probe_demod_addr (struct dvb_i2c_bus *i2c) } -static -int ves1820_attach (struct dvb_i2c_bus *i2c) +static int ves1820_attach (struct dvb_i2c_bus *i2c) { void *data = NULL; long demod_addr; @@ -539,23 +524,20 @@ int ves1820_attach (struct dvb_i2c_bus *i2c) } -static -void ves1820_detach (struct dvb_i2c_bus *i2c) +static void ves1820_detach (struct dvb_i2c_bus *i2c) { dvb_unregister_frontend (ves1820_ioctl, i2c); } -static -int __init init_ves1820 (void) +static int __init init_ves1820 (void) { return dvb_register_i2c_device (THIS_MODULE, ves1820_attach, ves1820_detach); } -static -void __exit exit_ves1820 (void) +static void __exit exit_ves1820 (void) { dvb_unregister_i2c_device (ves1820_attach); } |