diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-08-27 13:12:40 +1000 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-08-27 13:12:40 +1000 |
commit | f480fe3916de2e2cbb6e384cb685f0f1d8272188 (patch) | |
tree | 141c60a2a263f1c01907e692d4aef1e6b699d8c7 /fs/buffer.c | |
parent | 4f0dbc2781b9dc457159b676289f874ab2dc3560 (diff) | |
parent | f415c413f458837bd0c27086b79aca889f9435e4 (diff) |
Merge commit 'origin/master' into next
Diffstat (limited to 'fs/buffer.c')
-rw-r--r-- | fs/buffer.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/fs/buffer.c b/fs/buffer.c index a3ef091a45b..28f320fac4d 100644 --- a/fs/buffer.c +++ b/fs/buffer.c @@ -1165,8 +1165,11 @@ void mark_buffer_dirty(struct buffer_head *bh) if (!test_set_buffer_dirty(bh)) { struct page *page = bh->b_page; - if (!TestSetPageDirty(page)) - __set_page_dirty(page, page_mapping(page), 0); + if (!TestSetPageDirty(page)) { + struct address_space *mapping = page_mapping(page); + if (mapping) + __set_page_dirty(page, mapping, 0); + } } } |