Skip to contentSkip to conversation

Need i_mutex on lookup in a really really read-only fs?

DISCUSSION Valerie Aurora 1 participant 1 message Oct 11, 2009 VFS

lore
Share & tools
lore
#0 lore raw

Hey all,

Given a file system that is mounted really really read-only[1], do we still need the directory i_mutex when doing a lookup through a writable overlay/union mount? If not, we can probably union together several read-only file systems underneath a writable layer without any lock ordering problems.

Even with only one read-only layer, getting rid of the i_mutex during lookup would simplify the locking strategy significantly.

Writable overlay/union mounts doc here:

http://lkml.org/lkml/2009/10/1/291

-VAL

[1] VFS: Add read-only users count to superblock

    http://lwn.net/Articles/341129/