patch-2.4.22 linux-2.4.22/include/asm-s390x/pgtable.h

Next file: linux-2.4.22/include/asm-s390x/qdio.h
Previous file: linux-2.4.22/include/asm-s390x/page.h
Back to the patch index
Back to the overall index

diff -urN linux-2.4.21/include/asm-s390x/pgtable.h linux-2.4.22/include/asm-s390x/pgtable.h
@@ -158,7 +158,6 @@
 
 /* Bits in the page table entry */
 #define _PAGE_PRESENT   0x001          /* Software                         */
-#define _PAGE_MKCLEAN   0x002          /* Software                         */
 #define _PAGE_ISCLEAN   0x004          /* Software                         */
 #define _PAGE_RO        0x200          /* HW read-only                     */
 #define _PAGE_INVALID   0x400          /* HW invalid                       */
@@ -227,28 +226,9 @@
  */
 extern inline void set_pte(pte_t *pteptr, pte_t pteval)
 {
-	if ((pte_val(pteval) & (_PAGE_MKCLEAN|_PAGE_INVALID))
-	    == _PAGE_MKCLEAN) 
-	{
-		pte_val(pteval) &= ~_PAGE_MKCLEAN;
-               
-		asm volatile ("sske %0,%1" 
-				: : "d" (STORAGE_ACC_KEY_MASK),
-				"a" (pte_val(pteval)));
-	}
-
 	*pteptr = pteval;
 }
 
-extern inline void set_access_key(pte_t pteval)
-{
-	asm volatile ("    iske 0,%1\n"
-		      "    or   0,%0\n"
-		      "    sske 0,%1\n"
-			: : "d" (STORAGE_ACC_KEY_MASK),
-			"a" (pte_val(pteval)) : "0", "cc");
-}
-
 #define pages_to_mb(x) ((x) >> (20-PAGE_SHIFT))
 
 /*
@@ -420,7 +400,7 @@
 	 * sske instruction is slow. It is faster to let the
 	 * next instruction set the dirty bit.
 	 */
-	pte_val(pte) &= ~(_PAGE_MKCLEAN | _PAGE_ISCLEAN);
+	pte_val(pte) &= ~_PAGE_ISCLEAN;
 	return pte;
 }
 
@@ -462,7 +442,7 @@
 	/* We can't clear the changed bit atomically. For now we
          * clear (!) the page referenced bit. */
 	asm volatile ("sske %0,%1" 
-	              : : "d" (STORAGE_ACC_KEY_MASK), "a" (*ptep));
+	              : : "d" (0), "a" (*ptep));
 	return 1;
 }
 
@@ -501,15 +481,15 @@
 	pgprot_t __pgprot = (pgprot);					  \
 	unsigned long __physpage = __pa((__page-mem_map) << PAGE_SHIFT);  \
 	pte_t __pte = mk_pte_phys(__physpage, __pgprot);                  \
- 	                                                                  \
-	if (!(pgprot_val(__pgprot) & _PAGE_ISCLEAN)) {			  \
-		int __users = !!__page->buffers + !!__page->mapping;      \
-		if (__users + page_count(__page) == 1)                    \
-			pte_val(__pte) |= _PAGE_MKCLEAN;                  \
-	}								  \
 	__pte;                                                            \
 })
 
+#define arch_set_page_uptodate(__page)					  \
+	do {								  \
+		asm volatile ("sske %0,%1" : : "d" (0),			  \
+			      "a" (__pa((__page-mem_map) << PAGE_SHIFT)));\
+	} while (0)
+
 #define pte_page(x) (mem_map+(unsigned long)((pte_val(x) >> PAGE_SHIFT)))
 
 #define pmd_page(pmd) \

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)