summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorOleg Nesterov <oleg@redhat.com>2013-11-12 15:10:04 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2013-11-13 12:09:24 +0900
commit6bc080d8fdae33f4463203a400cfaa01e91701e2 (patch)
tree3d88fc27cc2b9d87f63340bd415adabef1380c29 /fs
parent93be3c2eb3371f022ad88acf1ab6bee8e3c38378 (diff)
downloadlinux-6bc080d8fdae33f4463203a400cfaa01e91701e2.tar.bz2
debugfs: use list_next_entry() in debugfs_remove_recursive()
Change debugfs_remove_recursive() to use list_next_entry(child), no changes in generated code. Signed-off-by: Oleg Nesterov <oleg@redhat.com> Cc: Eilon Greenstein <eilong@broadcom.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs')
-rw-r--r--fs/debugfs/inode.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/debugfs/inode.c b/fs/debugfs/inode.c
index c7c83ff0f752..9c0444cccbe1 100644
--- a/fs/debugfs/inode.c
+++ b/fs/debugfs/inode.c
@@ -566,8 +566,7 @@ void debugfs_remove_recursive(struct dentry *dentry)
mutex_lock(&parent->d_inode->i_mutex);
if (child != dentry) {
- next = list_entry(child->d_u.d_child.next, struct dentry,
- d_u.d_child);
+ next = list_next_entry(child, d_u.d_child);
goto up;
}