Re: [PATCH] riscv: Fix compilation error with FAST_GUP and rv32

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 3/4/24 00:02, Alexandre Ghiti wrote:
> By surrounding the definition of pte_leaf_size() with a ifdef napot as
> it should have been.
> 
> Fixes: e0fe5ab4192c ("riscv: Fix pte_leaf_size() for NAPOT")
> Signed-off-by: Alexandre Ghiti <alexghiti@xxxxxxxxxxxx>


Reviewed-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
Tested-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx> # build-tested

Thanks.

> ---
>  arch/riscv/include/asm/pgtable.h | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/arch/riscv/include/asm/pgtable.h b/arch/riscv/include/asm/pgtable.h
> index 25ca14f6942c..54d26a07fa63 100644
> --- a/arch/riscv/include/asm/pgtable.h
> +++ b/arch/riscv/include/asm/pgtable.h
> @@ -439,9 +439,11 @@ static inline pte_t pte_mkhuge(pte_t pte)
>  	return pte;
>  }
>  
> +#ifdef CONFIG_RISCV_ISA_SVNAPOT
>  #define pte_leaf_size(pte)	(pte_napot(pte) ?				\
>  					napot_cont_size(napot_cont_order(pte)) :\
>  					PAGE_SIZE)
> +#endif
>  
>  #ifdef CONFIG_NUMA_BALANCING
>  /*

-- 
#Randy




[Index of Archives]     [Linux Kernel]     [Linux USB Development]     [Yosemite News]     [Linux SCSI]

  Powered by Linux