Skip to contentSkip to conversation

nfs mmap vs i_mutex inversion

DISCUSSION Peter Zijlstra 1 participant 1 message Oct 2, 2008 Memory management

lore
Share & tools
lore
#0 lore raw

Hi Trond,

About that lock order inversion I remembered, I still have the patches:

http://programming.kicks-ass.net/kernel-patches/mmap-vs-nfs/

Although they would want updating a little.

But looking at a recent (.27-rc5-mm1) the offending code path:

down_write(&mm->mmap_sem)
...
->nfs_file_mmap()

    nfs_revalidate_mapping()
      nfs_invalidate_mapping()
        mutex_lock(&inode->i_mutex);

vs the regular order of

inode->i_mutex

    mm->mmap_sem

as described in mm/rmap.c

Seems to still exist.

If you agree its a valid concern, I'll brush up the patches and repost.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>