--- 2.4.10pre14/mm/vmscan.c	Sat Sep 22 08:06:24 2001
+++ swap/mm/vmscan.c	Sat Sep 22 09:35:52 2001
@@ -77,6 +77,14 @@
 	flush_tlb_page(vma, address);
 
 	/*
+	 * Just check that the cpu really triggers a page fault
+	 * also between the "ptep_get_and_clear" and the
+	 * "flush_tlb_page", and not just after the "flush_tlb_page".
+	 */
+	if (ptep_test_and_clear_dirty(page_table))
+		BUG();
+
+	/*
 	 * Is the page already in the swap cache? If so, then
 	 * we can just drop our reference to it without doing
 	 * any IO - it's already up-to-date on disk.