aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mtd/mtd.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/mtd/mtd.h')
-rw-r--r--include/linux/mtd/mtd.h16
1 files changed, 4 insertions, 12 deletions
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index d644e57703ad..6a8570be331b 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -85,6 +85,10 @@ typedef enum {
85 * mode = MTD_OOB_PLACE) 85 * mode = MTD_OOB_PLACE)
86 * @datbuf: data buffer - if NULL only oob data are read/written 86 * @datbuf: data buffer - if NULL only oob data are read/written
87 * @oobbuf: oob data buffer 87 * @oobbuf: oob data buffer
88 *
89 * Note, it is allowed to read more then one OOB area at one go, but not write.
90 * The interface assumes that the OOB write requests program only one page's
91 * OOB area.
88 */ 92 */
89struct mtd_oob_ops { 93struct mtd_oob_ops {
90 mtd_oob_mode_t mode; 94 mtd_oob_mode_t mode;
@@ -117,18 +121,6 @@ struct mtd_info {
117 u_int32_t writesize; 121 u_int32_t writesize;
118 122
119 u_int32_t oobsize; // Amount of OOB data per block (e.g. 16) 123 u_int32_t oobsize; // Amount of OOB data per block (e.g. 16)
120 u_int32_t ecctype;
121 u_int32_t eccsize;
122
123 /*
124 * Reuse some of the above unused fields in the case of NOR flash
125 * with configurable programming regions to avoid modifying the
126 * user visible structure layout/size. Only valid when the
127 * MTD_PROGRAM_REGIONS flag is set.
128 * (Maybe we should have an union for those?)
129 */
130#define MTD_PROGREGION_CTRLMODE_VALID(mtd) (mtd)->oobsize
131#define MTD_PROGREGION_CTRLMODE_INVALID(mtd) (mtd)->ecctype
132 124
133 // Kernel-only stuff starts here. 125 // Kernel-only stuff starts here.
134 char *name; 126 char *name;