Skip to content

RFC configfs: Make nested default groups lockdep-friendly

Louis Rilling lkml ocfs2-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest3 patches 15 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3configfs: set CONFIGFS_USET_DEFAULT earlier in configfs_attach_group()fs/configfs/dir.c+12 -100 replies
2/3configfs: Silence lockdep when creating nested default groupsfs/configfs/dir.c+17 -00 replies
3/3configfs: Silence lockdep when destroying default groupsfs/configfs/dir.c+17 -10 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC][PATCH 0/3] configfs: Make nested default groups lockdep-friendly

Hi all,

The following patches fix lockdep warnings resulting from (correct) recursive locking in configfs.

Current lockdep annotations for inode mutexes in configfs are lockdep-friendly provided that:
1/ config_groups have at most one level of default groups (see
configfs_attach_group()),
2/ config_groups having default groups are never removed (see
configfs_detach_prep()).

Since lockdep does not handle such correct recursion, the idea is to insert lockdep_off()/lockdep_on() for inode mutexes as soon as the level of recursion of the I_MUTEX_PARENT -> I_MUTEX_CHILD dependency pattern increases.

The patches apply to latest configfs in linux-2.6.git ( commit 8033c6e9736c29cce5f0d0abbca9a44dffb20c39 for instance ), and were successfully tested.

Signature · 4 lines
Dr Louis Rilling			Kerlabs
Skype: louis.rilling			Batiment Germanium
Phone: (+33|0) 6 80 89 08 23		80 avenue des Buttes de Coesmes
http://www.kerlabs.com/			35700 Rennes