diff options
Diffstat (limited to 'include/linux/mtd/onenand.h')
-rw-r--r-- | include/linux/mtd/onenand.h | 77 |
1 files changed, 44 insertions, 33 deletions
diff --git a/include/linux/mtd/onenand.h b/include/linux/mtd/onenand.h index 9ce9a48db44..1f497215524 100644 --- a/include/linux/mtd/onenand.h +++ b/include/linux/mtd/onenand.h | |||
@@ -23,7 +23,7 @@ extern int onenand_scan(struct mtd_info *mtd, int max_chips); | |||
23 | /* Free resources held by the OneNAND device */ | 23 | /* Free resources held by the OneNAND device */ |
24 | extern void onenand_release(struct mtd_info *mtd); | 24 | extern void onenand_release(struct mtd_info *mtd); |
25 | 25 | ||
26 | /** | 26 | /* |
27 | * onenand_state_t - chip states | 27 | * onenand_state_t - chip states |
28 | * Enumeration for OneNAND flash chip state | 28 | * Enumeration for OneNAND flash chip state |
29 | */ | 29 | */ |
@@ -42,9 +42,9 @@ typedef enum { | |||
42 | 42 | ||
43 | /** | 43 | /** |
44 | * struct onenand_bufferram - OneNAND BufferRAM Data | 44 | * struct onenand_bufferram - OneNAND BufferRAM Data |
45 | * @param block block address in BufferRAM | 45 | * @block: block address in BufferRAM |
46 | * @param page page address in BufferRAM | 46 | * @page: page address in BufferRAM |
47 | * @param valid valid flag | 47 | * @valid: valid flag |
48 | */ | 48 | */ |
49 | struct onenand_bufferram { | 49 | struct onenand_bufferram { |
50 | int block; | 50 | int block; |
@@ -54,32 +54,43 @@ struct onenand_bufferram { | |||
54 | 54 | ||
55 | /** | 55 | /** |
56 | * struct onenand_chip - OneNAND Private Flash Chip Data | 56 | * struct onenand_chip - OneNAND Private Flash Chip Data |
57 | * @param base [BOARDSPECIFIC] address to access OneNAND | 57 | * @base: [BOARDSPECIFIC] address to access OneNAND |
58 | * @param chipsize [INTERN] the size of one chip for multichip arrays | 58 | * @chipsize: [INTERN] the size of one chip for multichip arrays |
59 | * @param device_id [INTERN] device ID | 59 | * @device_id: [INTERN] device ID |
60 | * @param verstion_id [INTERN] version ID | 60 | * @density_mask: chip density, used for DDP devices |
61 | * @param options [BOARDSPECIFIC] various chip options. They can partly be set to inform onenand_scan about | 61 | * @verstion_id: [INTERN] version ID |
62 | * @param erase_shift [INTERN] number of address bits in a block | 62 | * @options: [BOARDSPECIFIC] various chip options. They can |
63 | * @param page_shift [INTERN] number of address bits in a page | 63 | * partly be set to inform onenand_scan about |
64 | * @param ppb_shift [INTERN] number of address bits in a pages per block | 64 | * @erase_shift: [INTERN] number of address bits in a block |
65 | * @param page_mask [INTERN] a page per block mask | 65 | * @page_shift: [INTERN] number of address bits in a page |
66 | * @param bufferam_index [INTERN] BufferRAM index | 66 | * @ppb_shift: [INTERN] number of address bits in a pages per block |
67 | * @param bufferam [INTERN] BufferRAM info | 67 | * @page_mask: [INTERN] a page per block mask |
68 | * @param readw [REPLACEABLE] hardware specific function for read short | 68 | * @bufferram_index: [INTERN] BufferRAM index |
69 | * @param writew [REPLACEABLE] hardware specific function for write short | 69 | * @bufferram: [INTERN] BufferRAM info |
70 | * @param command [REPLACEABLE] hardware specific function for writing commands to the chip | 70 | * @readw: [REPLACEABLE] hardware specific function for read short |
71 | * @param wait [REPLACEABLE] hardware specific function for wait on ready | 71 | * @writew: [REPLACEABLE] hardware specific function for write short |
72 | * @param read_bufferram [REPLACEABLE] hardware specific function for BufferRAM Area | 72 | * @command: [REPLACEABLE] hardware specific function for writing |
73 | * @param write_bufferram [REPLACEABLE] hardware specific function for BufferRAM Area | 73 | * commands to the chip |
74 | * @param read_word [REPLACEABLE] hardware specific function for read register of OneNAND | 74 | * @wait: [REPLACEABLE] hardware specific function for wait on ready |
75 | * @param write_word [REPLACEABLE] hardware specific function for write register of OneNAND | 75 | * @read_bufferram: [REPLACEABLE] hardware specific function for BufferRAM Area |
76 | * @param scan_bbt [REPLACEALBE] hardware specific function for scaning Bad block Table | 76 | * @write_bufferram: [REPLACEABLE] hardware specific function for BufferRAM Area |
77 | * @param chip_lock [INTERN] spinlock used to protect access to this structure and the chip | 77 | * @read_word: [REPLACEABLE] hardware specific function for read |
78 | * @param wq [INTERN] wait queue to sleep on if a OneNAND operation is in progress | 78 | * register of OneNAND |
79 | * @param state [INTERN] the current state of the OneNAND device | 79 | * @write_word: [REPLACEABLE] hardware specific function for write |
80 | * @param ecclayout [REPLACEABLE] the default ecc placement scheme | 80 | * register of OneNAND |
81 | * @param bbm [REPLACEABLE] pointer to Bad Block Management | 81 | * @mmcontrol: sync burst read function |
82 | * @param priv [OPTIONAL] pointer to private chip date | 82 | * @block_markbad: function to mark a block as bad |
83 | * @scan_bbt: [REPLACEALBE] hardware specific function for scanning | ||
84 | * Bad block Table | ||
85 | * @chip_lock: [INTERN] spinlock used to protect access to this | ||
86 | * structure and the chip | ||
87 | * @wq: [INTERN] wait queue to sleep on if a OneNAND | ||
88 | * operation is in progress | ||
89 | * @state: [INTERN] the current state of the OneNAND device | ||
90 | * @page_buf: data buffer | ||
91 | * @ecclayout: [REPLACEABLE] the default ecc placement scheme | ||
92 | * @bbm: [REPLACEABLE] pointer to Bad Block Management | ||
93 | * @priv: [OPTIONAL] pointer to private chip date | ||
83 | */ | 94 | */ |
84 | struct onenand_chip { | 95 | struct onenand_chip { |
85 | void __iomem *base; | 96 | void __iomem *base; |
@@ -147,9 +158,9 @@ struct onenand_chip { | |||
147 | #define ONENAND_MFR_SAMSUNG 0xec | 158 | #define ONENAND_MFR_SAMSUNG 0xec |
148 | 159 | ||
149 | /** | 160 | /** |
150 | * struct nand_manufacturers - NAND Flash Manufacturer ID Structure | 161 | * struct onenand_manufacturers - NAND Flash Manufacturer ID Structure |
151 | * @param name: Manufacturer name | 162 | * @name: Manufacturer name |
152 | * @param id: manufacturer ID code of device. | 163 | * @id: manufacturer ID code of device. |
153 | */ | 164 | */ |
154 | struct onenand_manufacturers { | 165 | struct onenand_manufacturers { |
155 | int id; | 166 | int id; |