]> www.infradead.org Git - users/willy/xarray.git/commitdiff
powerpc/mm: remove _PAGE_PSIZE
authorChristophe Leroy <christophe.leroy@csgroup.eu>
Tue, 2 Jul 2024 13:51:21 +0000 (15:51 +0200)
committerAndrew Morton <akpm@linux-foundation.org>
Fri, 12 Jul 2024 22:52:16 +0000 (15:52 -0700)
_PAGE_PSIZE macro is never used outside the place it is defined and is
used only on 8xx and e500.

Remove indirection, remove it and use its content directly.

Link: https://lkml.kernel.org/r/c41da3b0ceda7311a50f0391cc4d54302ae15b74.1719928057.git.christophe.leroy@csgroup.eu
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Reviewed-by: Oscar Salvador <osalvador@suse.de>
Cc: Jason Gunthorpe <jgg@nvidia.com>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Nicholas Piggin <npiggin@gmail.com>
Cc: Peter Xu <peterx@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/powerpc/include/asm/nohash/32/pte-44x.h
arch/powerpc/include/asm/nohash/32/pte-85xx.h
arch/powerpc/include/asm/nohash/32/pte-8xx.h
arch/powerpc/include/asm/nohash/pte-e500.h

index 8518137252371d7231a463c87715d9350b07b9d0..da04699282734b86d54e8069665f1abb8f324e67 100644 (file)
@@ -75,9 +75,6 @@
 #define _PAGE_NO_CACHE 0x00000400              /* H: I bit */
 #define _PAGE_WRITETHRU        0x00000800              /* H: W bit */
 
-/* No page size encoding in the linux PTE */
-#define _PAGE_PSIZE            0
-
 /* TODO: Add large page lowmem mapping support */
 #define _PMD_PRESENT   0
 #define _PMD_PRESENT_MASK (PAGE_MASK)
index 653a342d3b253ce9efaba09ae534b9286051828e..14d64b4f3f14a2b94e1598299975f69b75843bd5 100644 (file)
@@ -31,9 +31,6 @@
 #define _PAGE_WRITETHRU        0x00400 /* H: W bit */
 #define _PAGE_SPECIAL  0x00800 /* S: Special page */
 
-/* No page size encoding in the linux PTE */
-#define _PAGE_PSIZE            0
-
 #define _PMD_PRESENT   0
 #define _PMD_PRESENT_MASK (PAGE_MASK)
 #define _PMD_BAD       (~PAGE_MASK)
index 137dc3c84e456de8ab187a6717cde1fa4896a71c..625c31d6ce5cd94f7f773539b5ac899e197da162 100644 (file)
 #define _PTE_NONE_MASK 0
 
 #ifdef CONFIG_PPC_16K_PAGES
-#define _PAGE_PSIZE    _PAGE_SPS
+#define _PAGE_BASE_NC  (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_SPS)
 #else
-#define _PAGE_PSIZE            0
+#define _PAGE_BASE_NC  (_PAGE_PRESENT | _PAGE_ACCESSED)
 #endif
 
-#define _PAGE_BASE_NC  (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_PSIZE)
 #define _PAGE_BASE     (_PAGE_BASE_NC)
 
 #include <asm/pgtable-masks.h>
index f516f0b5b7a82f747db47b2f2a3a8482175fdb9e..975facc7e38ed2d447c0db09a50d67afcf42b5ac 100644 (file)
@@ -65,8 +65,6 @@
 
 #define _PAGE_SPECIAL  _PAGE_SW0
 
-/* Base page size */
-#define _PAGE_PSIZE    _PAGE_PSIZE_4K
 #define        PTE_RPN_SHIFT   (24)
 
 #define PTE_WIMGE_SHIFT (19)
@@ -89,7 +87,7 @@
  * pages. We always set _PAGE_COHERENT when SMP is enabled or
  * the processor might need it for DMA coherency.
  */
-#define _PAGE_BASE_NC  (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_PSIZE)
+#define _PAGE_BASE_NC  (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_PSIZE_4K)
 #if defined(CONFIG_SMP)
 #define _PAGE_BASE     (_PAGE_BASE_NC | _PAGE_COHERENT)
 #else