The patch titled epoll: move kfree inside ep_free has been added to the -mm tree. Its filename is epoll-move-kfree-inside-ep_free.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: epoll: move kfree inside ep_free From: Davide Libenzi <davidel@xxxxxxxxxxxxxxx> Move the kfree() call inside the ep_free() function. Signed-off-by: Davide Libenzi <davidel@xxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- fs/eventpoll.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff -puN fs/eventpoll.c~epoll-move-kfree-inside-ep_free fs/eventpoll.c --- a/fs/eventpoll.c~epoll-move-kfree-inside-ep_free +++ a/fs/eventpoll.c @@ -469,18 +469,16 @@ static void ep_free(struct eventpoll *ep } mutex_unlock(&epmutex); - mutex_destroy(&ep->mtx); + kfree(ep); } static int ep_eventpoll_release(struct inode *inode, struct file *file) { struct eventpoll *ep = file->private_data; - if (ep) { + if (ep) ep_free(ep); - kfree(ep); - } DNPRINTK(3, (KERN_INFO "[%p] eventpoll: close() ep=%p\n", current, ep)); return 0; @@ -1107,7 +1105,6 @@ asmlinkage long sys_epoll_create(int siz error_free: ep_free(ep); - kfree(ep); error_return: DNPRINTK(3, (KERN_INFO "[%p] eventpoll: sys_epoll_create(%d) = %d\n", current, size, error)); _ Patches currently in -mm which might be from davidel@xxxxxxxxxxxxxxx are fix-epoll-single-pass-code-and-add-wait-exclusive-flag.patch epoll-locks-changes-and-cleanups.patch epoll-fix-some-comments.patch epoll-move-kfree-inside-ep_free.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html