提交 3a6b974d 编写于 作者: M Michael Krufky 提交者: Mauro Carvalho Chehab

V4L/DVB (8658): lgs8gl5: fix build warnings

Fix the following build warnings:

lgs8gl5.c: In function 'lgs8gl5_read_reg':
lgs8gl5.c:95: warning: unused variable 'j'
lgs8gl5.c: In function 'lgs8gl5_update_alt_reg':
lgs8gl5.c:135: warning: unused variable 'j'
lgs8gl5.c: In function 'lgs8gl5_read_ber':
lgs8gl5.c:300: warning: unused variable 'state'
lgs8gl5.c: In function 'lgs8gl5_read_ucblocks':
lgs8gl5.c:332: warning: unused variable 'state'
lgs8gl5.c: At top level:
lgs8gl5.c:181: warning: 'lgs8gl5_set_inversion' defined but not used
Signed-off-by: NMichael Krufky <mkrufky@linuxtv.org>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 dfbdce04
...@@ -92,7 +92,7 @@ lgs8gl5_write_reg(struct lgs8gl5_state *state, u8 reg, u8 data) ...@@ -92,7 +92,7 @@ lgs8gl5_write_reg(struct lgs8gl5_state *state, u8 reg, u8 data)
static int static int
lgs8gl5_read_reg(struct lgs8gl5_state *state, u8 reg) lgs8gl5_read_reg(struct lgs8gl5_state *state, u8 reg)
{ {
int ret, j; int ret;
u8 b0[] = {reg}; u8 b0[] = {reg};
u8 b1[] = {0}; u8 b1[] = {0};
struct i2c_msg msg[2] = { struct i2c_msg msg[2] = {
...@@ -132,7 +132,7 @@ lgs8gl5_update_reg(struct lgs8gl5_state *state, u8 reg, u8 data) ...@@ -132,7 +132,7 @@ lgs8gl5_update_reg(struct lgs8gl5_state *state, u8 reg, u8 data)
static int static int
lgs8gl5_update_alt_reg(struct lgs8gl5_state *state, u8 reg, u8 data) lgs8gl5_update_alt_reg(struct lgs8gl5_state *state, u8 reg, u8 data)
{ {
int ret, j; int ret;
u8 b0[] = {reg}; u8 b0[] = {reg};
u8 b1[] = {0}; u8 b1[] = {0};
u8 b2[] = {reg, data}; u8 b2[] = {reg, data};
...@@ -176,30 +176,6 @@ lgs8gl5_soft_reset(struct lgs8gl5_state *state) ...@@ -176,30 +176,6 @@ lgs8gl5_soft_reset(struct lgs8gl5_state *state)
} }
static int
lgs8gl5_set_inversion(struct lgs8gl5_state *state, int inversion)
{
u8 val;
dprintk("%s\n", __func__);
switch (inversion) {
case INVERSION_AUTO:
return -EOPNOTSUPP;
case INVERSION_ON:
val = lgs8gl5_read_reg(state, REG_INVERSION);
return lgs8gl5_write_reg(state, REG_INVERSION,
val | REG_INVERSION_ON);
case INVERSION_OFF:
val = lgs8gl5_read_reg(state, REG_INVERSION);
return lgs8gl5_write_reg(state, REG_INVERSION,
val & ~REG_INVERSION_ON);
default:
return -EINVAL;
}
}
/* Starts demodulation */ /* Starts demodulation */
static void static void
lgs8gl5_start_demod(struct lgs8gl5_state *state) lgs8gl5_start_demod(struct lgs8gl5_state *state)
...@@ -297,7 +273,6 @@ lgs8gl5_read_status(struct dvb_frontend *fe, fe_status_t *status) ...@@ -297,7 +273,6 @@ lgs8gl5_read_status(struct dvb_frontend *fe, fe_status_t *status)
static int static int
lgs8gl5_read_ber(struct dvb_frontend *fe, u32 *ber) lgs8gl5_read_ber(struct dvb_frontend *fe, u32 *ber)
{ {
struct lgs8gl5_state *state = fe->demodulator_priv;
*ber = 0; *ber = 0;
return 0; return 0;
...@@ -329,7 +304,6 @@ lgs8gl5_read_snr(struct dvb_frontend *fe, u16 *snr) ...@@ -329,7 +304,6 @@ lgs8gl5_read_snr(struct dvb_frontend *fe, u16 *snr)
static int static int
lgs8gl5_read_ucblocks(struct dvb_frontend *fe, u32 *ucblocks) lgs8gl5_read_ucblocks(struct dvb_frontend *fe, u32 *ucblocks)
{ {
struct lgs8gl5_state *state = fe->demodulator_priv;
*ucblocks = 0; *ucblocks = 0;
return 0; return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册