]> git.hungrycats.org Git - linux/commit
[PATCH] __set_page_dirty_nobuffers mappings
authorHugh Dickins <hugh@veritas.com>
Mon, 18 Oct 2004 15:54:48 +0000 (08:54 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Mon, 18 Oct 2004 15:54:48 +0000 (08:54 -0700)
commitc76aaef04194fdaad83dc6c27eb5edce77d4a7f9
tree6ae5722ba4efa497007b4e827a5a9af67238f25c
parentfef60c1b89ca4518a1b424854a3758a658bbe748
[PATCH] __set_page_dirty_nobuffers mappings

Marcelo noticed that the BUG_ON in __set_page_dirty_nobuffers doesn't make
much sense: it lost its way in 2.6.7, amidst so many page_mappings!

It's supposed to be checking that, although page->mapping may suddenly go NULL
from truncation, and although tmpfs swizzles page_mapping(page) between tmpfs
inode address_space and swapper_space, there's sufficient stabilization while
here in __set_page_dirty_nobuffers that the mapping after we locked
mapping->tree_lock is the same as the mapping before we locked
mapping->tree_lock i.e.  the lock we hold is the right one.

Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
mm/page-writeback.c