ChangeSet 1.2095, 2005/02/23 07:36:23-08:00, [EMAIL PROTECTED]
[PATCH] ppc32: Wrong vaddr in flush_hash_one_pte()
Reworking the ppc32 mm helps me find interesting bugs in the existing
bug,
well, brown paper bag for me, I made this one a while ago.
The routine flush_hash_one_pte() used by ptep_test_and_clear_young()
wasn't properly recaclulating the vaddr from the pte pointer &
page->index. The result is that we probably never flushed things from
the hash, so that's at least the _second_ bug affecting
ptep_test_and_clear_young(), swap on ppc32 must have been really broken
:(
This fixes it.
Signed-off-by: Benjamin Herrenschmidt <[EMAIL PROTECTED]>
Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
tlb.c | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
diff -Nru a/arch/ppc/mm/tlb.c b/arch/ppc/mm/tlb.c
--- a/arch/ppc/mm/tlb.c 2005-02-23 10:08:46 -08:00
+++ b/arch/ppc/mm/tlb.c 2005-02-23 10:08:46 -08:00
@@ -62,7 +62,7 @@
ptepage = virt_to_page(ptep);
mm = (struct mm_struct *) ptepage->mapping;
ptephys = __pa(ptep) & PAGE_MASK;
- addr = ptepage->index + (((unsigned long)ptep & ~PAGE_MASK) << 9);
+ addr = ptepage->index + (((unsigned long)ptep & ~PAGE_MASK) << 10);
flush_hash_pages(mm->context, addr, ptephys, 1);
}
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html