summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-03-09 10:34:55 -0800
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-03-09 10:34:55 -0800
commit6e96783f586cc0a64651087cb518209a8577123f (patch)
tree8b74a5a8fda055ffeaa0c1ae3c070772599f8b3b /include
parent8466c833799b30ab343c5108cd2e460f9f16c9d8 (diff)
parent0feba829ee82a6e43baabe3f0bdf91bd937a67a1 (diff)
downloadkernel-crypto-6e96783f586cc0a64651087cb518209a8577123f.tar.gz
kernel-crypto-6e96783f586cc0a64651087cb518209a8577123f.tar.xz
kernel-crypto-6e96783f586cc0a64651087cb518209a8577123f.zip
Merge git://git.infradead.org/mtd-2.6
* git://git.infradead.org/mtd-2.6: [JFFS2] print a message when marking bad block [JFFS2] Check for all-zero node headers [MTD] [OneNAND] Classify the page data and oob buffer [MTD] [OneNAND] Exit the loop when transferring/filling of the oob is finished [MTD] [OneNAND] add Nokia Copyright and a credit [MTD] [OneNAND] Fix typo & wrong comments [MTD] [OneNAND] Use oob buffer instead of main one in oob functions [MTD] Correct partition failed erase address [JFFS2] Use yield() between GC passes in background thread. [MTD] [NAND] Correct misspelled preprocessor variable. [MTD] [MAPS] dilnetpc: Fix printk warning [MTD] [NOR] Fix oops in cfi_amdstd_sync [MTD] ESB2 check for closed ROM window [JFFS2] Fix writebuffer recovery in the first page of a block [MTD] [NAND] make oobavail public
Diffstat (limited to 'include')
-rw-r--r--include/linux/mtd/mtd.h1
-rw-r--r--include/linux/mtd/onenand.h5
2 files changed, 5 insertions, 1 deletions
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index 6a8570be331..3d956c3abb3 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -121,6 +121,7 @@ struct mtd_info {
u_int32_t writesize;
u_int32_t oobsize; // Amount of OOB data per block (e.g. 16)
+ u_int32_t oobavail; // Available OOB bytes per block
// Kernel-only stuff starts here.
char *name;
diff --git a/include/linux/mtd/onenand.h b/include/linux/mtd/onenand.h
index d8af8a95e58..a56d24ada50 100644
--- a/include/linux/mtd/onenand.h
+++ b/include/linux/mtd/onenand.h
@@ -82,7 +82,8 @@ struct onenand_bufferram {
* @wq: [INTERN] wait queue to sleep on if a OneNAND
* operation is in progress
* @state: [INTERN] the current state of the OneNAND device
- * @page_buf: data buffer
+ * @page_buf: [INTERN] page main data buffer
+ * @oob_buf: [INTERN] page oob data buffer
* @subpagesize: [INTERN] holds the subpagesize
* @ecclayout: [REPLACEABLE] the default ecc placement scheme
* @bbm: [REPLACEABLE] pointer to Bad Block Management
@@ -122,6 +123,7 @@ struct onenand_chip {
wait_queue_head_t wq;
onenand_state_t state;
unsigned char *page_buf;
+ unsigned char *oob_buf;
int subpagesize;
struct nand_ecclayout *ecclayout;
@@ -156,6 +158,7 @@ struct onenand_chip {
#define ONENAND_HAS_CONT_LOCK (0x0001)
#define ONENAND_HAS_UNLOCK_ALL (0x0002)
#define ONENAND_PAGEBUF_ALLOC (0x1000)
+#define ONENAND_OOBBUF_ALLOC (0x2000)
/*
* OneNAND Flash Manufacturer ID Codes