]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
powerpc/nohash: Remove _PAGE_BUSY
authorChristophe Leroy <christophe.leroy@c-s.fr>
Tue, 24 Apr 2018 16:31:30 +0000 (18:31 +0200)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 7 May 2018 10:37:46 +0000 (20:37 +1000)
_PAGE_BUSY is always 0, remove it.

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/nohash/64/pgtable.h
arch/powerpc/include/asm/nohash/pte-book3e.h

index ef3fdfc04f927780e231186b498e2fb12ecef87c..6ac8381f4c7afe4ebd2a8510b05eb785c4907c48 100644 (file)
@@ -186,14 +186,12 @@ static inline unsigned long pte_update(struct mm_struct *mm,
 
        __asm__ __volatile__(
        "1:     ldarx   %0,0,%3         # pte_update\n\
-       andi.   %1,%0,%6\n\
-       bne-    1b \n\
        andc    %1,%0,%4 \n\
-       or      %1,%1,%7\n\
+       or      %1,%1,%6\n\
        stdcx.  %1,0,%3 \n\
        bne-    1b"
        : "=&r" (old), "=&r" (tmp), "=m" (*ptep)
-       : "r" (ptep), "r" (clr), "m" (*ptep), "i" (_PAGE_BUSY), "r" (set)
+       : "r" (ptep), "r" (clr), "m" (*ptep), "r" (set)
        : "cc" );
 #else
        unsigned long old = pte_val(*ptep);
@@ -295,13 +293,11 @@ static inline void __ptep_set_access_flags(struct mm_struct *mm,
 
        __asm__ __volatile__(
        "1:     ldarx   %0,0,%4\n\
-               andi.   %1,%0,%6\n\
-               bne-    1b \n\
                or      %0,%3,%0\n\
                stdcx.  %0,0,%4\n\
                bne-    1b"
        :"=&r" (old), "=&r" (tmp), "=m" (*ptep)
-       :"r" (bits), "r" (ptep), "m" (*ptep), "i" (_PAGE_BUSY)
+       :"r" (bits), "r" (ptep), "m" (*ptep)
        :"cc");
 #else
        unsigned long old = pte_val(*ptep);
index 9ff51b4c0cacd5fc7fb06c20b22836fc5003590c..12730b81cd9841560fa3f710e080bfa7632ae947 100644 (file)
 #define _PAGE_USER             (_PAGE_BAP_UR | _PAGE_BAP_SR) /* Can be read */
 #define _PAGE_PRIVILEGED       (_PAGE_BAP_SR)
 
-#define _PAGE_BUSY     0
-
 #define _PAGE_SPECIAL  _PAGE_SW0
 
-/* Flags to be preserved on PTE modifications */
-#define _PAGE_HPTEFLAGS        _PAGE_BUSY
-
 /* Base page size */
 #ifdef CONFIG_PPC_64K_PAGES
 #define _PAGE_PSIZE    _PAGE_PSIZE_64K