linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] fix potential infinite loop in debugfs_remove_recursive
@ 2019-11-15  3:27 yu kuai
  2019-11-15  3:27 ` [PATCH 1/3] dcache: add a new enum type for 'dentry_d_lock_class' yu kuai
                   ` (2 more replies)
  0 siblings, 3 replies; 25+ messages in thread
From: yu kuai @ 2019-11-15  3:27 UTC (permalink / raw)
  To: gregkh, rafael, viro, rostedt, oleg, mchehab+samsung, corbet,
	tytso, jmorris
  Cc: yukuai3, linux-kernel, linux-fsdevel, zhengbin13, yi.zhang,
	chenxiang66, xiexiuqi

The first patch add a new enum type for 'dentry_d_lock_class'.The second
patch use the new enum type in 'simple_empty' to avoid confusion for
lockdep. The last patch fix potential infinite loop in
debugfs_remove_recursive by using 'simple_empty' instead of 'list_empty'.

yu kuai (3):
  dcache: add a new enum type for 'dentry_d_lock_class'
  fs/libfs.c: use 'spin_lock_nested' when taking 'd_lock' for dentry in
    simple_empty
  debugfs: fix potential infinite loop in debugfs_remove_recursive

 fs/debugfs/inode.c     | 7 +++++--
 fs/libfs.c             | 4 ++--
 include/linux/dcache.h | 3 ++-
 3 files changed, 9 insertions(+), 5 deletions(-)

-- 
2.7.4


^ permalink raw reply	[flat|nested] 25+ messages in thread
* [PATCH V2 0/3] fix potential infinite loop in debugfs_remove_recursive
@ 2019-11-30  2:02 yu kuai
  2019-11-30  2:02 ` [PATCH 3/3] debugfs: " yu kuai
  0 siblings, 1 reply; 25+ messages in thread
From: yu kuai @ 2019-11-30  2:02 UTC (permalink / raw)
  To: gregkh, rafael, viro, rostedt, oleg, mchehab+samsung, corbet,
	tytso, jmorris
  Cc: linux-kernel, linux-fsdevel, yukuai3, zhengbin13, yi.zhang,
	chenxiang66, xiexiuqi

The main purpose of this patchset is to fix potential infinite loop in
debugfs_remove_recursive. Al Viro want to refactor it
(https://lore.kernel.org/lkml/20191115184209.GT26530@ZenIV.linux.org.uk/).
I can't really tell if it's better. Since debugfs_remove_recursive is
still using 'simple_empty', whitch is wrong, I'm sending this patchset
just in case.

The first patch add a new enum type for 'dentry_d_lock_class'.The second
patch use the new enum type in 'simple_empty' to avoid confusion for
lockdep. The last patch fix potential infinite loop in
debugfs_remove_recursive by using 'simple_empty' instead of 'list_empty'.

changes in V2:
rename the new enum type in the first patch, add some comments.


yu kuai (3):
  dcache: add a new enum type for 'dentry_d_lock_class'
  fs/libfs.c: use 'spin_lock_nested' when taking 'd_lock' for dentry in
    simple_empty
  debugfs: fix potential infinite loop in debugfs_remove_recursive

 fs/debugfs/inode.c     |  7 +++++--
 fs/libfs.c             |  4 ++--
 include/linux/dcache.h | 11 ++++++++++-
 3 files changed, 17 insertions(+), 5 deletions(-)

-- 
2.17.2


^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2019-11-30  1:41 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-15  3:27 [PATCH 0/3] fix potential infinite loop in debugfs_remove_recursive yu kuai
2019-11-15  3:27 ` [PATCH 1/3] dcache: add a new enum type for 'dentry_d_lock_class' yu kuai
2019-11-15  3:27   ` Greg KH
2019-11-15  4:12     ` Al Viro
2019-11-15  7:20       ` Greg KH
2019-11-15 10:08         ` yukuai (C)
2019-11-15 13:16         ` Al Viro
2019-11-15 13:38           ` Steven Rostedt
2019-11-15 13:39             ` Steven Rostedt
2019-11-15 13:48             ` Al Viro
2019-11-15 13:58               ` Steven Rostedt
2019-11-15 14:17                 ` Al Viro
2019-11-15 17:54                   ` Al Viro
2019-11-15 18:42                     ` [RFC] simple_recursive_removal() Al Viro
2019-11-15 19:41                       ` Al Viro
2019-11-15 21:18                         ` Al Viro
2019-11-15 21:26                           ` Steven Rostedt
2019-11-15 22:10                             ` Al Viro
2019-11-16 12:04                               ` Greg KH
2019-11-17 22:24                               ` Al Viro
2019-11-18  6:37                                 ` Greg KH
2019-11-15 10:02     ` [PATCH 1/3] dcache: add a new enum type for 'dentry_d_lock_class' yukuai (C)
2019-11-15  3:27 ` [PATCH 2/3] fs/libfs.c: use 'spin_lock_nested' when taking 'd_lock' for dentry in simple_empty yu kuai
2019-11-15  3:27 ` [PATCH 3/3] debugfs: fix potential infinite loop in debugfs_remove_recursive yu kuai
2019-11-30  2:02 [PATCH V2 0/3] " yu kuai
2019-11-30  2:02 ` [PATCH 3/3] debugfs: " yu kuai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).