diff options
author | Kyungmin Park <kyungmin.park@samsung.com> | 2010-12-06 01:05:18 +0100 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2011-01-06 16:16:39 +0100 |
commit | d983c54ebd875f5f6fd37c154195c1c456a7af70 (patch) | |
tree | f819b5d61328e35664262d6aced043d0c4a0609e /drivers/mtd/onenand/onenand_base.c | |
parent | Revert "mtd: nand: add check for out of page read" (diff) | |
download | linux-d983c54ebd875f5f6fd37c154195c1c456a7af70.tar.xz linux-d983c54ebd875f5f6fd37c154195c1c456a7af70.zip |
mtd: OneNAND: Fix multi block erase support at 4KiB pagesize
Original 4KiB pagesize chip (SLC) doesn't support Multi block erase at Spec.
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/mtd/onenand/onenand_base.c')
-rw-r--r-- | drivers/mtd/onenand/onenand_base.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/mtd/onenand/onenand_base.c b/drivers/mtd/onenand/onenand_base.c index c38bf9c54a11..88f23e3f3014 100644 --- a/drivers/mtd/onenand/onenand_base.c +++ b/drivers/mtd/onenand/onenand_base.c @@ -2492,7 +2492,8 @@ static int onenand_erase(struct mtd_info *mtd, struct erase_info *instr) /* Grab the lock and see if the device is available */ onenand_get_device(mtd, FL_ERASING); - if (region || instr->len < MB_ERASE_MIN_BLK_COUNT * block_size) { + if (ONENAND_IS_4KB_PAGE(this) || region || + instr->len < MB_ERASE_MIN_BLK_COUNT * block_size) { /* region is set for Flex-OneNAND (no mb erase) */ ret = onenand_block_by_block_erase(mtd, instr, region, block_size); |