Commit 3aeb30b0 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] give swapper_space a set_page_dirty a_op

Give swapper_space a ->set_page_dirty() address_space_operation.

So swapcache pages do not need special-casing in
set_page_dirty_buffers().
parent da9bfeb4
...@@ -497,7 +497,7 @@ int __set_page_dirty_buffers(struct page *page) ...@@ -497,7 +497,7 @@ int __set_page_dirty_buffers(struct page *page)
spin_lock(&mapping->private_lock); spin_lock(&mapping->private_lock);
if (page_has_buffers(page) && !PageSwapCache(page)) { if (page_has_buffers(page)) {
struct buffer_head *head = page_buffers(page); struct buffer_head *head = page_buffers(page);
struct buffer_head *bh = head; struct buffer_head *bh = head;
......
...@@ -48,9 +48,10 @@ static int swap_vm_writeback(struct page *page, int *nr_to_write) ...@@ -48,9 +48,10 @@ static int swap_vm_writeback(struct page *page, int *nr_to_write)
} }
static struct address_space_operations swap_aops = { static struct address_space_operations swap_aops = {
vm_writeback: swap_vm_writeback, vm_writeback: swap_vm_writeback,
writepage: swap_writepage, writepage: swap_writepage,
sync_page: block_sync_page, sync_page: block_sync_page,
set_page_dirty: __set_page_dirty_nobuffers,
}; };
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment