summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2008-06-19 22:58:36 +0200
committerWolfgang Denk <wd@denx.de>2008-06-19 22:58:36 +0200
commit914f58c5766860373a7d232e961cee5a4b54a55b (patch)
tree1f7f373079ec09168de183f164b7bf0c41b57386 /drivers
parent8115c6f9eb6b030cc52b61acdcb44cdf1d2876b8 (diff)
parentfb8c061ea05fc68d37e2a8b9f8c949d76c8d71a8 (diff)
downloadu-boot-imx-914f58c5766860373a7d232e961cee5a4b54a55b.zip
u-boot-imx-914f58c5766860373a7d232e961cee5a4b54a55b.tar.gz
u-boot-imx-914f58c5766860373a7d232e961cee5a4b54a55b.tar.bz2
Merge branch 'master' of git://www.denx.de/git/u-boot-cfi-flash
Diffstat (limited to 'drivers')
-rw-r--r--drivers/mtd/cfi_flash.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/drivers/mtd/cfi_flash.c b/drivers/mtd/cfi_flash.c
index d505bc8..c0ea97b 100644
--- a/drivers/mtd/cfi_flash.c
+++ b/drivers/mtd/cfi_flash.c
@@ -581,20 +581,16 @@ static int flash_toggle (flash_info_t * info, flash_sect_t sect,
flash_make_cmd (info, cmd, &cword);
switch (info->portwidth) {
case FLASH_CFI_8BIT:
- retval = ((flash_read8(addr) & cword.c) !=
- (flash_read8(addr) & cword.c));
+ retval = flash_read8(addr) != flash_read8(addr);
break;
case FLASH_CFI_16BIT:
- retval = ((flash_read16(addr) & cword.w) !=
- (flash_read16(addr) & cword.w));
+ retval = flash_read16(addr) != flash_read16(addr);
break;
case FLASH_CFI_32BIT:
- retval = ((flash_read32(addr) & cword.l) !=
- (flash_read32(addr) & cword.l));
+ retval = flash_read32(addr) != flash_read32(addr);
break;
case FLASH_CFI_64BIT:
- retval = ((flash_read64(addr) & cword.ll) !=
- (flash_read64(addr) & cword.ll));
+ retval = flash_read64(addr) != flash_read64(addr);
break;
default:
retval = 0;