diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-04-25 14:22:20 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-04-25 14:25:19 -0400 |
commit | 13122f98c6479ddbfc308eb4253f84aaf4a2b45e (patch) | |
tree | e9c723bfbab0044c7a27f234b6673f12319316dc | |
parent | 746f7ae0e9ca500f8be888675d88befed5740413 (diff) |
[media] dib8000: fix a warning
drivers/media/dvb-frontends/dib8000.c: In function 'dib8000_wait_lock':
drivers/media/dvb-frontends/dib8000.c:3972:1: warning: 'value' may be used uninitialized in this function [-Wmaybe-uninitialized]
drivers/media/dvb-frontends/dib8000.c:2419:6: note: 'value' was declared here
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r-- | drivers/media/dvb-frontends/dib8000.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/media/dvb-frontends/dib8000.c b/drivers/media/dvb-frontends/dib8000.c index 57863d3fd1cf..a54182dd0e91 100644 --- a/drivers/media/dvb-frontends/dib8000.c +++ b/drivers/media/dvb-frontends/dib8000.c | |||
@@ -2416,19 +2416,19 @@ static void dib8000_set_isdbt_common_channel(struct dib8000_state *state, u8 seq | |||
2416 | static u32 dib8000_wait_lock(struct dib8000_state *state, u32 internal, | 2416 | static u32 dib8000_wait_lock(struct dib8000_state *state, u32 internal, |
2417 | u32 wait0_ms, u32 wait1_ms, u32 wait2_ms) | 2417 | u32 wait0_ms, u32 wait1_ms, u32 wait2_ms) |
2418 | { | 2418 | { |
2419 | u32 value; | 2419 | u32 value = 0; /* P_search_end0 wait time */ |
2420 | u16 reg = 11; /* P_search_end0 start addr */ | 2420 | u16 reg = 11; /* P_search_end0 start addr */ |
2421 | 2421 | ||
2422 | for (reg = 11; reg < 16; reg += 2) { | 2422 | for (reg = 11; reg < 16; reg += 2) { |
2423 | if (reg == 11) { | 2423 | if (reg == 11) { |
2424 | if (state->revision == 0x8090) | 2424 | if (state->revision == 0x8090) |
2425 | value = internal * wait1_ms; /* P_search_end0 wait time */ | 2425 | value = internal * wait1_ms; |
2426 | else | 2426 | else |
2427 | value = internal * wait0_ms; /* P_search_end0 wait time */ | 2427 | value = internal * wait0_ms; |
2428 | } else if (reg == 13) | 2428 | } else if (reg == 13) |
2429 | value = internal * wait1_ms; /* P_search_end0 wait time */ | 2429 | value = internal * wait1_ms; |
2430 | else if (reg == 15) | 2430 | else if (reg == 15) |
2431 | value = internal * wait2_ms; /* P_search_end0 wait time */ | 2431 | value = internal * wait2_ms; |
2432 | dib8000_write_word(state, reg, (u16)((value >> 16) & 0xffff)); | 2432 | dib8000_write_word(state, reg, (u16)((value >> 16) & 0xffff)); |
2433 | dib8000_write_word(state, (reg + 1), (u16)(value & 0xffff)); | 2433 | dib8000_write_word(state, (reg + 1), (u16)(value & 0xffff)); |
2434 | } | 2434 | } |