author: Miles Chen <miles.chen@mediatek.com> 2021-09-02 14:57:13 -0700
committer: Linus Torvalds <torvalds@linux-foundation.org> 2021-09-03 09:58:14 -0700
commit: bdbda735508ca83341899a77f143e4d5c58007b3
parent: e0dbb2bccf19ce5e870afb420a3d0480c582bb7b
Commit Summary:
Diffstat:
1 file changed, 2 insertions, 1 deletion
diff --git a/mm/sparse.c b/mm/sparse.c
index be7936e65b6a..fd29b3abffa0 100644
--- a/mm/sparse.c
+++ b/mm/sparse.c
@@ -321,7 +321,8 @@ size_t mem_section_usage_size(void)
static inline phys_addr_t pgdat_to_phys(struct pglist_data *pgdat)
{
#ifndef CONFIG_NUMA
- return __pa_symbol(pgdat);
+ VM_BUG_ON(pgdat != &contig_page_data);
+ return __pa_symbol(&contig_page_data);
#else
return __pa(pgdat);
#endif