| Message ID | 20260811042119.3652929-6-anshuman.khandual@arm.com |
|---|---|
| State | New |
| Headers | show |
| Series | mm: Drop pxd_ERROR() | expand |
On 8/11/26 06:21, Anshuman Khandual wrote: > Stop using pgd_ERROR() in __get_pte_phys() when page table entry is already > known to be empty. > > Cc: Yoshinori Sato <ysato@users.sourceforge.jp> > Cc: Rich Felker <dalias@libc.org> > Cc: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de> > Cc: linux-sh@vger.kernel.org > Cc: linux-kernel@vger.kernel.org > Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com> > --- > arch/sh/mm/init.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/arch/sh/mm/init.c b/arch/sh/mm/init.c > index 0bb8555568a4..585012293632 100644 > --- a/arch/sh/mm/init.c > +++ b/arch/sh/mm/init.c > @@ -52,10 +52,8 @@ static pte_t *__get_pte_phys(unsigned long addr) > pmd_t *pmd; > > pgd = pgd_offset_k(addr); > - if (pgd_none(*pgd)) { > - pgd_ERROR(*pgd); > + if (pgd_none(*pgd)) > return NULL; > - } > > p4d = p4d_alloc(NULL, pgd, addr); > if (unlikely(!p4d)) Reviewed-by: David Hildenbrand (Arm) <david@kernel.org>
diff --git a/arch/sh/mm/init.c b/arch/sh/mm/init.c index 0bb8555568a4..585012293632 100644 --- a/arch/sh/mm/init.c +++ b/arch/sh/mm/init.c @@ -52,10 +52,8 @@ static pte_t *__get_pte_phys(unsigned long addr) pmd_t *pmd; pgd = pgd_offset_k(addr); - if (pgd_none(*pgd)) { - pgd_ERROR(*pgd); + if (pgd_none(*pgd)) return NULL; - } p4d = p4d_alloc(NULL, pgd, addr); if (unlikely(!p4d))
Stop using pgd_ERROR() in __get_pte_phys() when page table entry is already known to be empty. Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: Rich Felker <dalias@libc.org> Cc: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de> Cc: linux-sh@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com> --- arch/sh/mm/init.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)