diff options
Diffstat (limited to 'linux/drivers/media/dvb/frontends/grundig_29504-491.c')
-rw-r--r-- | linux/drivers/media/dvb/frontends/grundig_29504-491.c | 66 |
1 files changed, 22 insertions, 44 deletions
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); } |