The patch titled
(re)register_binfmt returns with -EBUSY
has been added to the -mm tree. Its filename is
reregister_binfmt-returns-with-ebusy.patch
*** Remember to use Documentation/SubmitChecklist when testing your code ***
See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this
------------------------------------------------------
Subject: (re)register_binfmt returns with -EBUSY
From: "kalash nainwal" <[EMAIL PROTECTED]>
When a binary format is unregistered and re-registered, register_binfmt
fails with -EBUSY. The reason is that unregister_binfmt does not set
fmt->next to NULL, and seeing (fmt->next != NULL), register_binfmt fails
with -EBUSY.
One can find his way around by explicitly setting fmt->next to NULL after
unregistering, but that is kind of unclean (one should better be using only
the interfaces, and not the interal members, isn't it?)
Attached one-liner can fix it.
Signed-off-by: Kalash Nainwal <[EMAIL PROTECTED]>
Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
---
fs/exec.c | 1 +
1 files changed, 1 insertion(+)
diff -puN fs/exec.c~reregister_binfmt-returns-with-ebusy fs/exec.c
--- a/fs/exec.c~reregister_binfmt-returns-with-ebusy
+++ a/fs/exec.c
@@ -100,6 +100,7 @@ int unregister_binfmt(struct linux_binfm
while (*tmp) {
if (fmt == *tmp) {
*tmp = fmt->next;
+ fmt->next = NULL;
write_unlock(&binfmt_lock);
return 0;
}
_
Patches currently in -mm which might be from [EMAIL PROTECTED] are
reregister_binfmt-returns-with-ebusy.patch
-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html