summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJörn Engel2007-09-21 15:41:44 +0200
committerDavid Woodhouse2007-09-21 15:48:33 +0200
commitb38178ee712e8608f20c8e741adf97f75f1aea39 (patch)
treed8f78e72985a32b7aae9ef34eec6e76233cdee84 /include
parent[MTD] Remove Momenco Ocelot NOR flash support (diff)
downloadkernel-qcow2-linux-b38178ee712e8608f20c8e741adf97f75f1aea39.tar.gz
kernel-qcow2-linux-b38178ee712e8608f20c8e741adf97f75f1aea39.tar.xz
kernel-qcow2-linux-b38178ee712e8608f20c8e741adf97f75f1aea39.zip
[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>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mtd/mtd.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index fd64ccfbce02..783fc983417c 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -133,6 +133,13 @@ struct mtd_info {
int numeraseregions;
struct mtd_erase_region_info *eraseregions;
+ /*
+ * Erase is an asynchronous operation. Device drivers are supposed
+ * to call instr->callback() whenever the operation completes, even
+ * if it completes with a failure.
+ * Callers are supposed to pass a callback function and wait for it
+ * to be called before writing to the block.
+ */
int (*erase) (struct mtd_info *mtd, struct erase_info *instr);
/* This stuff for eXecute-In-Place */