From: Stelian Pop Date: Mon, 14 Jan 2008 21:08:14 +0000 (+0100) Subject: Fix incorrect address test in AT91F_DataflashSelect(). X-Git-Tag: v1.3.2-rc1~35 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=c77ce474b1c57b13e9d36d9830f147966c143694;p=oweals%2Fu-boot.git Fix incorrect address test in AT91F_DataflashSelect(). Signed-off-by: Stelian Pop --- diff --git a/drivers/mtd/dataflash.c b/drivers/mtd/dataflash.c index 91903c8c8f..3ebb7064f2 100644 --- a/drivers/mtd/dataflash.c +++ b/drivers/mtd/dataflash.c @@ -304,7 +304,7 @@ AT91PS_DataFlash AT91F_DataflashSelect (AT91PS_DataFlash pFlash, for (i = 0; i < CFG_MAX_DATAFLASH_BANKS; i++) if ( dataflash_info[i].id - && ((((int) addr) & 0xFF000000) == + && ((((int) *addr) & 0xFF000000) == dataflash_info[i].logical_address)) { addr_valid = 1; break;