diff options
Diffstat (limited to 'mm')
-rw-r--r-- | mm/page-writeback.c | 10 | ||||
-rw-r--r-- | mm/shmem.c | 2 |
2 files changed, 11 insertions, 1 deletions
diff --git a/mm/page-writeback.c b/mm/page-writeback.c index be0efbde4994..438833cbbca4 100644 --- a/mm/page-writeback.c +++ b/mm/page-writeback.c | |||
@@ -737,6 +737,16 @@ int write_one_page(struct page *page, int wait) | |||
737 | EXPORT_SYMBOL(write_one_page); | 737 | EXPORT_SYMBOL(write_one_page); |
738 | 738 | ||
739 | /* | 739 | /* |
740 | * For address_spaces which do not use buffers nor write back. | ||
741 | */ | ||
742 | int __set_page_dirty_no_writeback(struct page *page) | ||
743 | { | ||
744 | if (!PageDirty(page)) | ||
745 | SetPageDirty(page); | ||
746 | return 0; | ||
747 | } | ||
748 | |||
749 | /* | ||
740 | * For address_spaces which do not use buffers. Just tag the page as dirty in | 750 | * For address_spaces which do not use buffers. Just tag the page as dirty in |
741 | * its radix tree. | 751 | * its radix tree. |
742 | * | 752 | * |
diff --git a/mm/shmem.c b/mm/shmem.c index 70da7a0981bf..b38e17169271 100644 --- a/mm/shmem.c +++ b/mm/shmem.c | |||
@@ -2316,7 +2316,7 @@ static void destroy_inodecache(void) | |||
2316 | 2316 | ||
2317 | static const struct address_space_operations shmem_aops = { | 2317 | static const struct address_space_operations shmem_aops = { |
2318 | .writepage = shmem_writepage, | 2318 | .writepage = shmem_writepage, |
2319 | .set_page_dirty = __set_page_dirty_nobuffers, | 2319 | .set_page_dirty = __set_page_dirty_no_writeback, |
2320 | #ifdef CONFIG_TMPFS | 2320 | #ifdef CONFIG_TMPFS |
2321 | .prepare_write = shmem_prepare_write, | 2321 | .prepare_write = shmem_prepare_write, |
2322 | .commit_write = simple_commit_write, | 2322 | .commit_write = simple_commit_write, |