* [PATCH] [MTD] Document erase interface.
@ 2007-09-21 13:41 Jörn Engel
2007-09-21 14:14 ` Josh Boyer
0 siblings, 1 reply; 3+ messages in thread
From: Jörn Engel @ 2007-09-21 13:41 UTC (permalink / raw)
To: David Woodhouse; +Cc: linux-mtd
Document mtd erase interface.
Signed-off-by: Jörn Engel <joern@logfs.org>
---
include/linux/mtd/mtd.h | 7 +++++++
1 file changed, 7 insertions(+)
--- linux-2.6.21logfs/include/linux/mtd/mtd.h~mtd_erase_documentation 2007-05-31 13:41:41.000000000 +0200
+++ linux-2.6.21logfs/include/linux/mtd/mtd.h 2007-09-21 15:43:18.000000000 +0200
@@ -139,6 +139,13 @@ struct mtd_info {
/* This really shouldn't be here. It can go away in 2.5 */
u_int32_t bank_size;
+ /*
+ * 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 */
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] [MTD] Document erase interface.
2007-09-21 13:41 [PATCH] [MTD] Document erase interface Jörn Engel
@ 2007-09-21 14:14 ` Josh Boyer
2007-09-21 14:14 ` Jörn Engel
0 siblings, 1 reply; 3+ messages in thread
From: Josh Boyer @ 2007-09-21 14:14 UTC (permalink / raw)
To: Jörn Engel; +Cc: linux-mtd, David Woodhouse
On Fri, 21 Sep 2007 15:41:44 +0200
Jörn Engel <joern@logfs.org> wrote:
> Document mtd erase interface.
>
> Signed-off-by: Jörn Engel <joern@logfs.org>
> ---
>
> include/linux/mtd/mtd.h | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> --- linux-2.6.21logfs/include/linux/mtd/mtd.h~mtd_erase_documentation 2007-05-31 13:41:41.000000000 +0200
> +++ linux-2.6.21logfs/include/linux/mtd/mtd.h 2007-09-21 15:43:18.000000000 +0200
> @@ -139,6 +139,13 @@ struct mtd_info {
> /* This really shouldn't be here. It can go away in 2.5 */
> u_int32_t bank_size;
>
> + /*
> + * 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);
If you're going to go to the trouble, maybe doing it in KernelDoc style
would be better.
josh
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] [MTD] Document erase interface.
2007-09-21 14:14 ` Josh Boyer
@ 2007-09-21 14:14 ` Jörn Engel
0 siblings, 0 replies; 3+ messages in thread
From: Jörn Engel @ 2007-09-21 14:14 UTC (permalink / raw)
To: Josh Boyer; +Cc: linux-mtd, Jörn Engel, David Woodhouse
On Fri, 21 September 2007 09:14:41 -0500, Josh Boyer wrote:
>
> If you're going to go to the trouble, maybe doing it in KernelDoc style
> would be better.
Feel free to send a better patch.
Jörn
--
Joern's library part 2:
http://www.art.net/~hopkins/Don/unix-haters/tirix/embarrassing-memo.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-09-21 14:19 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-09-21 13:41 [PATCH] [MTD] Document erase interface Jörn Engel
2007-09-21 14:14 ` Josh Boyer
2007-09-21 14:14 ` Jörn Engel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox