diff options
author | Manu Abraham <abraham.manu@gmail.com> | 2008-01-25 18:28:46 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-12-29 14:53:22 -0500 |
commit | 85eabac439ff6b60775e3d6458702dcb6c479e05 (patch) | |
tree | 34c5f1f5b5b6babd82dcf29748e7619e1e7c55f4 /drivers/media/dvb | |
parent | d6812086508a38ccb48ed9d5bc9f50732dc818db (diff) |
V4L/DVB (9453): stb0899: fix compilation warnings
Cleanup/Optimization:
* Fix compile warnings
* The compile warnings helped to identify 2 unnecessary I/O operations
Signed-off-by: Manu Abraham <manu@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/dvb')
-rw-r--r-- | drivers/media/dvb/frontends/stb0899_algo.c | 8 | ||||
-rw-r--r-- | drivers/media/dvb/frontends/stb0899_drv.c | 2 | ||||
-rw-r--r-- | drivers/media/dvb/frontends/stb0899_priv.h | 2 |
3 files changed, 4 insertions, 8 deletions
diff --git a/drivers/media/dvb/frontends/stb0899_algo.c b/drivers/media/dvb/frontends/stb0899_algo.c index f1432cb29262..65bc032964b1 100644 --- a/drivers/media/dvb/frontends/stb0899_algo.c +++ b/drivers/media/dvb/frontends/stb0899_algo.c | |||
@@ -199,9 +199,7 @@ static enum stb0899_status stb0899_check_tmg(struct stb0899_state *state) | |||
199 | 199 | ||
200 | msleep(internal->t_timing); | 200 | msleep(internal->t_timing); |
201 | 201 | ||
202 | reg = stb0899_read_reg(state, STB0899_RTF); | 202 | stb0899_write_reg(state, STB0899_RTF, 0xf2); |
203 | STB0899_SETFIELD_VAL(RTF_TIMING_LOOP_FREQ, reg, 0xf2); | ||
204 | stb0899_write_reg(state, STB0899_RTF, reg); | ||
205 | reg = stb0899_read_reg(state, STB0899_TLIR); | 203 | reg = stb0899_read_reg(state, STB0899_TLIR); |
206 | lock = STB0899_GETFIELD(TLIR_TMG_LOCK_IND, reg); | 204 | lock = STB0899_GETFIELD(TLIR_TMG_LOCK_IND, reg); |
207 | timing = stb0899_read_reg(state, STB0899_RTF); | 205 | timing = stb0899_read_reg(state, STB0899_RTF); |
@@ -603,9 +601,7 @@ enum stb0899_status stb0899_dvbs_algo(struct stb0899_state *state) | |||
603 | cfr[0] = cfr[1] = 0; | 601 | cfr[0] = cfr[1] = 0; |
604 | stb0899_write_regs(state, STB0899_CFRM, cfr, 2); /* RESET derotator frequency */ | 602 | stb0899_write_regs(state, STB0899_CFRM, cfr, 2); /* RESET derotator frequency */ |
605 | 603 | ||
606 | reg = stb0899_read_reg(state, STB0899_RTF); | 604 | stb0899_write_reg(state, STB0899_RTF, 0); |
607 | STB0899_SETFIELD_VAL(RTF_TIMING_LOOP_FREQ, reg, 0); | ||
608 | stb0899_write_reg(state, STB0899_RTF, reg); | ||
609 | reg = stb0899_read_reg(state, STB0899_CFD); | 605 | reg = stb0899_read_reg(state, STB0899_CFD); |
610 | STB0899_SETFIELD_VAL(CFD_ON, reg, 1); | 606 | STB0899_SETFIELD_VAL(CFD_ON, reg, 1); |
611 | stb0899_write_reg(state, STB0899_CFD, reg); | 607 | stb0899_write_reg(state, STB0899_CFD, reg); |
diff --git a/drivers/media/dvb/frontends/stb0899_drv.c b/drivers/media/dvb/frontends/stb0899_drv.c index 2caa192a8e7e..6e7db9912749 100644 --- a/drivers/media/dvb/frontends/stb0899_drv.c +++ b/drivers/media/dvb/frontends/stb0899_drv.c | |||
@@ -495,7 +495,7 @@ err: | |||
495 | return status < 0 ? status : -EREMOTEIO; | 495 | return status < 0 ? status : -EREMOTEIO; |
496 | } | 496 | } |
497 | 497 | ||
498 | int stb0899_write_regs(struct stb0899_state *state, unsigned int reg, u8 *data, size_t count) | 498 | int stb0899_write_regs(struct stb0899_state *state, unsigned int reg, u8 *data, u32 count) |
499 | { | 499 | { |
500 | int ret; | 500 | int ret; |
501 | u8 buf[2 + count]; | 501 | u8 buf[2 + count]; |
diff --git a/drivers/media/dvb/frontends/stb0899_priv.h b/drivers/media/dvb/frontends/stb0899_priv.h index 73790b4e3453..da7fddb4e6be 100644 --- a/drivers/media/dvb/frontends/stb0899_priv.h +++ b/drivers/media/dvb/frontends/stb0899_priv.h | |||
@@ -242,7 +242,7 @@ extern int stb0899_read_regs(struct stb0899_state *state, | |||
242 | 242 | ||
243 | extern int stb0899_write_regs(struct stb0899_state *state, | 243 | extern int stb0899_write_regs(struct stb0899_state *state, |
244 | unsigned int reg, u8 *data, | 244 | unsigned int reg, u8 *data, |
245 | size_t count); | 245 | u32 count); |
246 | 246 | ||
247 | extern int stb0899_write_reg(struct stb0899_state *state, | 247 | extern int stb0899_write_reg(struct stb0899_state *state, |
248 | unsigned int reg, | 248 | unsigned int reg, |