Commit b38178ee712e8608f20c8e741adf97f75f1aea39
Committed by
David Woodhouse
1 parent
5041f1f1b7
Exists in
master
and in
7 other branches
[MTD] Document erase interface.
Document mtd erase interface. Signed-off-by: Jörn Engel <joern@logfs.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Showing 1 changed file with 7 additions and 0 deletions Side-by-side Diff
include/linux/mtd/mtd.h
... | ... | @@ -133,6 +133,13 @@ |
133 | 133 | int numeraseregions; |
134 | 134 | struct mtd_erase_region_info *eraseregions; |
135 | 135 | |
136 | + /* | |
137 | + * Erase is an asynchronous operation. Device drivers are supposed | |
138 | + * to call instr->callback() whenever the operation completes, even | |
139 | + * if it completes with a failure. | |
140 | + * Callers are supposed to pass a callback function and wait for it | |
141 | + * to be called before writing to the block. | |
142 | + */ | |
136 | 143 | int (*erase) (struct mtd_info *mtd, struct erase_info *instr); |
137 | 144 | |
138 | 145 | /* This stuff for eXecute-In-Place */ |