mm/nommu: share the i_mmap_rwsem
authorDavidlohr Bueso <[email protected]>
Sat, 13 Dec 2014 00:54:39 +0000 (16:54 -0800)
committerLinus Torvalds <[email protected]>
Sat, 13 Dec 2014 20:42:46 +0000 (12:42 -0800)
commit1acf2e040721564d579297646862b8ea3dd4511b
treec51ec6206f123b9d09caed4878d4958314d497db
parentd28eb9c861f41aa2af4cfcc5eeeddff42b13d31e
mm/nommu: share the i_mmap_rwsem

Shrinking/truncate logic can call nommu_shrink_inode_mappings() to verify
that any shared mappings of the inode in question aren't broken (dead
zone).  afaict the only user being ramfs to handle the size change
attribute.

Pretty much a no-brainer to share the lock.

Signed-off-by: Davidlohr Bueso <[email protected]>
Acked-by: "Kirill A. Shutemov" <[email protected]>
Acked-by: Hugh Dickins <[email protected]>
Cc: Oleg Nesterov <[email protected]>
Acked-by: Peter Zijlstra (Intel) <[email protected]>
Cc: Rik van Riel <[email protected]>
Cc: Srikar Dronamraju <[email protected]>
Acked-by: Mel Gorman <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
mm/nommu.c