diff options
author | KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> | 2007-10-16 04:25:43 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-16 12:42:59 -0400 |
commit | 97ee052461446526e1de7236497e6f1b1ffedf8c (patch) | |
tree | 7c91270577191ed32de22d8183695c1354d555c8 | |
parent | 4106f83a9f86afc423557d0d92ebf4b3f36728c1 (diff) |
flush cache before installing new page at migraton
In migration, a new page should be cache flushed before set_pte() in some
archs which have virtually-tagged cache.
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Christoph Lameter <clameter@sgi.com>
Cc: Hugh Dickins <hugh@veritas.com>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | mm/migrate.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/mm/migrate.c b/mm/migrate.c index 71c38b43c019..ea11ddb58275 100644 --- a/mm/migrate.c +++ b/mm/migrate.c | |||
@@ -171,6 +171,7 @@ static void remove_migration_pte(struct vm_area_struct *vma, | |||
171 | pte = pte_mkold(mk_pte(new, vma->vm_page_prot)); | 171 | pte = pte_mkold(mk_pte(new, vma->vm_page_prot)); |
172 | if (is_write_migration_entry(entry)) | 172 | if (is_write_migration_entry(entry)) |
173 | pte = pte_mkwrite(pte); | 173 | pte = pte_mkwrite(pte); |
174 | flush_cache_page(vma, addr, pte_pfn(pte)); | ||
174 | set_pte_at(mm, addr, ptep, pte); | 175 | set_pte_at(mm, addr, ptep, pte); |
175 | 176 | ||
176 | if (PageAnon(new)) | 177 | if (PageAnon(new)) |