summaryrefslogtreecommitdiff
path: root/firmware/src/dfu
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2011-11-09 23:24:12 +0100
committerHarald Welte <laforge@gnumonks.org>2011-11-10 07:33:53 +0100
commit7ab4135217dc431134a988122528ecbaf344c574 (patch)
treea30908d80ed8cdbd8855cb21da32dff5b5543fae /firmware/src/dfu
parent3d60f2e042891420f871628b62be879567fce8c6 (diff)
dfu: The i variable to disable interrupts shadows the outer index
In case ram_app_entry() returns do not reset i to 32, otherwise we will never reset the watchdog. src/dfu/dfu.c:1077:7: warning: declaration of ā€˜iā€™ shadows a previous local [-Wshadow] src/dfu/dfu.c:1068:6: warning: shadowed declaration is here [-Wshadow]
Diffstat (limited to 'firmware/src/dfu')
-rw-r--r--firmware/src/dfu/dfu.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/firmware/src/dfu/dfu.c b/firmware/src/dfu/dfu.c
index 0e22256..48f2cdc 100644
--- a/firmware/src/dfu/dfu.c
+++ b/firmware/src/dfu/dfu.c
@@ -1074,9 +1074,9 @@ void __dfufunc dfu_main(void)
}
if (switch_to_ram) {
void (*ram_app_entry)(void);
- int i;
- for (i = 0; i < 32; i++)
- AT91F_AIC_DisableIt(AT91C_BASE_AIC, i);
+ int j;
+ for (j = 0; j < 32; j++)
+ AT91F_AIC_DisableIt(AT91C_BASE_AIC, j);
/* jump into RAM */
AT91F_DBGU_Printk("JUMP TO RAM\r\n");
ram_app_entry = AT91C_ISRAM + SAM7DFU_RAM_SIZE;
personal git repositories of Harald Welte. Your mileage may vary