Skip to content

Commit 8b4c07b

Browse files
chenhuacaigregkh
authored andcommitted
LoongArch: Fix build error due to backport
In 6.1 there is no pmdp_get() definition, so use *pmd directly, in order to avoid such build error due to a recently backport: arch/loongarch/mm/hugetlbpage.c: In function 'huge_pte_offset': arch/loongarch/mm/hugetlbpage.c:50:25: error: implicit declaration of function 'pmdp_get'; did you mean 'ptep_get'? [-Wimplicit-function-declaration] 50 | return pmd_none(pmdp_get(pmd)) ? NULL : (pte_t *) pmd; | ^~~~~~~~ | ptep_get Reported-by: Guenter Roeck <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Huacai Chen <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent b6736e0 commit 8b4c07b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/loongarch/mm/hugetlbpage.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ pte_t *huge_pte_offset(struct mm_struct *mm, unsigned long addr,
4747
pmd = pmd_offset(pud, addr);
4848
}
4949
}
50-
return pmd_none(pmdp_get(pmd)) ? NULL : (pte_t *) pmd;
50+
return pmd_none(*pmd) ? NULL : (pte_t *) pmd;
5151
}
5252

5353
/*

0 commit comments

Comments
 (0)