diff mbox series

sparc32: add stub pud_page define for walking huge vmalloc page tables

Message ID 20210324232825.1157363-1-npiggin@gmail.com (mailing list archive)
State New, archived
Headers show
Series sparc32: add stub pud_page define for walking huge vmalloc page tables | expand

Commit Message

Nicholas Piggin March 24, 2021, 11:28 p.m. UTC
Similarly to the stub p4d_page in sparc64, add a stub pud_page, this
is needed for hugepages in the vmap page tables to be walked without
ifdefs, which should be no functional change for sparc32.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---

This should go in Andrew's mm tree which has a compile error on sparc32
introduced by the huge vmalloc pages, noticed by Stephen.

Thanks,
Nick

 arch/sparc/include/asm/pgtable_32.h | 3 +++
 1 file changed, 3 insertions(+)

Comments

David Miller March 24, 2021, 11:32 p.m. UTC | #1
From: Nicholas Piggin <npiggin@gmail.com>
Date: Thu, 25 Mar 2021 09:28:25 +1000

> Similarly to the stub p4d_page in sparc64, add a stub pud_page, this
> is needed for hugepages in the vmap page tables to be walked without
> ifdefs, which should be no functional change for sparc32.
> 
> Signed-off-by: Nicholas Piggin <npiggin@gmail.com>

Acked-by: David S. Miller <davem@davemloft.net>
Stephen Rothwell March 25, 2021, 9:17 p.m. UTC | #2
Hi all,

On Thu, 25 Mar 2021 09:28:25 +1000 Nicholas Piggin <npiggin@gmail.com> wrote:
>
> Similarly to the stub p4d_page in sparc64, add a stub pud_page, this
> is needed for hugepages in the vmap page tables to be walked without
> ifdefs, which should be no functional change for sparc32.
> 
> Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
> ---
> 
> This should go in Andrew's mm tree which has a compile error on sparc32
> introduced by the huge vmalloc pages, noticed by Stephen.
> 
> Thanks,
> Nick
> 
>  arch/sparc/include/asm/pgtable_32.h | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/sparc/include/asm/pgtable_32.h b/arch/sparc/include/asm/pgtable_32.h
> index 632cdb959542..a5cf79c149fe 100644
> --- a/arch/sparc/include/asm/pgtable_32.h
> +++ b/arch/sparc/include/asm/pgtable_32.h
> @@ -321,6 +321,9 @@ static inline pte_t pte_modify(pte_t pte, pgprot_t newprot)
>  		pgprot_val(newprot));
>  }
>  
> +/* only used by the huge vmap code, should never be called */
> +#define pud_page(pud)			NULL
> +
>  struct seq_file;
>  void mmu_info(struct seq_file *m);
>  
> -- 
> 2.23.0
> 

I have used this instead of my hack fix in linux-next today.
diff mbox series

Patch

diff --git a/arch/sparc/include/asm/pgtable_32.h b/arch/sparc/include/asm/pgtable_32.h
index 632cdb959542..a5cf79c149fe 100644
--- a/arch/sparc/include/asm/pgtable_32.h
+++ b/arch/sparc/include/asm/pgtable_32.h
@@ -321,6 +321,9 @@  static inline pte_t pte_modify(pte_t pte, pgprot_t newprot)
 		pgprot_val(newprot));
 }
 
+/* only used by the huge vmap code, should never be called */
+#define pud_page(pud)			NULL
+
 struct seq_file;
 void mmu_info(struct seq_file *m);