diff options
author | Mika Korhonen <ext-mika.2.korhonen@nokia.com> | 2009-10-23 01:50:43 -0400 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2009-11-30 04:43:18 -0500 |
commit | 72073027ee95d059eb5a064da4a978efab36d4ab (patch) | |
tree | a7ee5f24092602d7fda6c34db6781c3de2d415d8 /include/linux/mtd | |
parent | 73885aeaca046a21183db598c2da46529e46fdab (diff) |
mtd: OneNAND: multiblock erase support
Add support for multiblock erase command. OneNANDs (excluding Flex-OneNAND)
are capable of simultaneous erase of up to 64 eraseblocks which is much faster.
This changes the erase requests for regions covering multiple eraseblocks
to be performed using multiblock erase.
Signed-off-by: Mika Korhonen <ext-mika.2.korhonen@nokia.com>
Reviewed-by: Adrian Hunter <adrian.hunter@nokia.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'include/linux/mtd')
-rw-r--r-- | include/linux/mtd/flashchip.h | 4 | ||||
-rw-r--r-- | include/linux/mtd/onenand_regs.h | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/include/linux/mtd/flashchip.h b/include/linux/mtd/flashchip.h index f350a4879f75..d0bf422ae374 100644 --- a/include/linux/mtd/flashchip.h +++ b/include/linux/mtd/flashchip.h | |||
@@ -41,9 +41,11 @@ typedef enum { | |||
41 | /* These 2 come from nand_state_t, which has been unified here */ | 41 | /* These 2 come from nand_state_t, which has been unified here */ |
42 | FL_READING, | 42 | FL_READING, |
43 | FL_CACHEDPRG, | 43 | FL_CACHEDPRG, |
44 | /* These 2 come from onenand_state_t, which has been unified here */ | 44 | /* These 4 come from onenand_state_t, which has been unified here */ |
45 | FL_RESETING, | 45 | FL_RESETING, |
46 | FL_OTPING, | 46 | FL_OTPING, |
47 | FL_PREPARING_ERASE, | ||
48 | FL_VERIFYING_ERASE, | ||
47 | 49 | ||
48 | FL_UNKNOWN | 50 | FL_UNKNOWN |
49 | } flstate_t; | 51 | } flstate_t; |
diff --git a/include/linux/mtd/onenand_regs.h b/include/linux/mtd/onenand_regs.h index acadbf53a69f..cd6f3b431195 100644 --- a/include/linux/mtd/onenand_regs.h +++ b/include/linux/mtd/onenand_regs.h | |||
@@ -131,6 +131,8 @@ | |||
131 | #define ONENAND_CMD_LOCK_TIGHT (0x2C) | 131 | #define ONENAND_CMD_LOCK_TIGHT (0x2C) |
132 | #define ONENAND_CMD_UNLOCK_ALL (0x27) | 132 | #define ONENAND_CMD_UNLOCK_ALL (0x27) |
133 | #define ONENAND_CMD_ERASE (0x94) | 133 | #define ONENAND_CMD_ERASE (0x94) |
134 | #define ONENAND_CMD_MULTIBLOCK_ERASE (0x95) | ||
135 | #define ONENAND_CMD_ERASE_VERIFY (0x71) | ||
134 | #define ONENAND_CMD_RESET (0xF0) | 136 | #define ONENAND_CMD_RESET (0xF0) |
135 | #define ONENAND_CMD_OTP_ACCESS (0x65) | 137 | #define ONENAND_CMD_OTP_ACCESS (0x65) |
136 | #define ONENAND_CMD_READID (0x90) | 138 | #define ONENAND_CMD_READID (0x90) |