[MTD] Use single flag to mark writeable devices.
Linux-MTD Mailing List
linux-mtd at lists.infradead.org
Mon May 22 17:59:01 EDT 2006
Commit: 8ca9ed5db3aea8d27989c239e8a2f79b839f1e99
Parent: 987d47b71a85bd83dc40c870abee3b64f2002163
Author: Joern Engel <joern at wh.fh-wedel.de>
AuthorDate: Mon May 22 23:17:23 2006 +0200
Commit: Joern Engel <joern at wh.fh-wedel.de>
CommitDate: Mon May 22 23:17:23 2006 +0200
[MTD] Use single flag to mark writeable devices.
Two flags exist to decide whether a device is writeable or not. None of
those two flags is checked for independently, so they are clearly redundant,
if not an invitation to bugs. This patch removed both of them, replacing
them with a single new flag.
Signed-off-by: Joern Engel <joern at wh.fh-wedel.de>
include/mtd/mtd-abi.h | 10 ++++------
1 files changed, 4 insertions(+), 6 deletions(-)
diff --git a/include/mtd/mtd-abi.h b/include/mtd/mtd-abi.h
index fa25241..e4d61f3 100644
--- a/include/mtd/mtd-abi.h
+++ b/include/mtd/mtd-abi.h
@@ -30,17 +30,15 @@ #define MTD_NORFLASH 3
#define MTD_NANDFLASH 4
#define MTD_DATAFLASH 6
-#define MTD_CLEAR_BITS 1 // Bits can be cleared (flash)
-#define MTD_SET_BITS 2 // Bits can be set
#define MTD_ECC 128 // Device capable of automatic ECC
#define MTD_PROGRAM_REGIONS 512 // Configurable Programming Regions
+#define MTD_WRITEABLE 0x400 /* Device is writeable */
// Some common devices / combinations of capabilities
#define MTD_CAP_ROM 0
-#define MTD_CAP_RAM (MTD_CLEAR_BITS|MTD_SET_BITS)
-#define MTD_CAP_NORFLASH (MTD_CLEAR_BITS)
-#define MTD_CAP_NANDFLASH (MTD_CLEAR_BITS)
-#define MTD_WRITEABLE (MTD_CLEAR_BITS|MTD_SET_BITS)
+#define MTD_CAP_RAM (MTD_WRITEABLE)
+#define MTD_CAP_NORFLASH (MTD_WRITEABLE)
+#define MTD_CAP_NANDFLASH (MTD_WRITEABLE)
// Types of automatic ECC/Checksum available
More information about the linux-mtd-cvs
mailing list