Skip to content
Snippets Groups Projects
Commit 6d68621c authored by Stefan Roese's avatar Stefan Roese Committed by Wolfgang Denk
Browse files

nand_boot.c: Fix GCC 4.6 build warnings


Fix:
nand_boot.c: In function 'nand_read_page':
nand_boot.c:190:6: warning: variable 'stat' set but not used [-Wunused-but-set-variable]
nand_boot.c: In function 'nand_boot':
nand_boot.c:271:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable]

Signed-off-by: default avatarStefan Roese <sr@denx.de>
parent 13a8c8d0
Branches
Tags
No related merge requests found
...@@ -187,7 +187,6 @@ static int nand_read_page(struct mtd_info *mtd, int block, int page, uchar *dst) ...@@ -187,7 +187,6 @@ static int nand_read_page(struct mtd_info *mtd, int block, int page, uchar *dst)
int eccbytes = CONFIG_SYS_NAND_ECCBYTES; int eccbytes = CONFIG_SYS_NAND_ECCBYTES;
int eccsteps = CONFIG_SYS_NAND_ECCSTEPS; int eccsteps = CONFIG_SYS_NAND_ECCSTEPS;
uint8_t *p = dst; uint8_t *p = dst;
int stat;
nand_command(mtd, block, page, 0, NAND_CMD_READ0); nand_command(mtd, block, page, 0, NAND_CMD_READ0);
...@@ -217,7 +216,7 @@ static int nand_read_page(struct mtd_info *mtd, int block, int page, uchar *dst) ...@@ -217,7 +216,7 @@ static int nand_read_page(struct mtd_info *mtd, int block, int page, uchar *dst)
* from correct_data(). We just hope that all possible errors * from correct_data(). We just hope that all possible errors
* are corrected by this routine. * are corrected by this routine.
*/ */
stat = this->ecc.correct(mtd, p, &ecc_code[i], &ecc_calc[i]); this->ecc.correct(mtd, p, &ecc_code[i], &ecc_calc[i]);
} }
return 0; return 0;
...@@ -268,7 +267,6 @@ void nand_boot(void) ...@@ -268,7 +267,6 @@ void nand_boot(void)
{ {
struct nand_chip nand_chip; struct nand_chip nand_chip;
nand_info_t nand_info; nand_info_t nand_info;
int ret;
__attribute__((noreturn)) void (*uboot)(void); __attribute__((noreturn)) void (*uboot)(void);
/* /*
...@@ -287,7 +285,7 @@ void nand_boot(void) ...@@ -287,7 +285,7 @@ void nand_boot(void)
/* /*
* Load U-Boot image from NAND into RAM * Load U-Boot image from NAND into RAM
*/ */
ret = nand_load(&nand_info, CONFIG_SYS_NAND_U_BOOT_OFFS, CONFIG_SYS_NAND_U_BOOT_SIZE, nand_load(&nand_info, CONFIG_SYS_NAND_U_BOOT_OFFS, CONFIG_SYS_NAND_U_BOOT_SIZE,
(uchar *)CONFIG_SYS_NAND_U_BOOT_DST); (uchar *)CONFIG_SYS_NAND_U_BOOT_DST);
#ifdef CONFIG_NAND_ENV_DST #ifdef CONFIG_NAND_ENV_DST
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment