Skip to contentSkip to conversation

openrisc: mm: Fix section mismatch between map_page and __set_fixmap

PATCH New Stafford Horne 1 participant 1 message Mar 21 Openrisc architecture

lore
Share & tools
lore

Stafford Horne

author maintainer
#0 lore raw

PATCH 1/1 openrisc: mm: Fix section mismatch between map_page and __set_fixmap

This warning was reported by the kernel test robot:

WARNING: modpost: vmlinux: section mismatch in reference: __set_fixmap+0x84 (section: .text.unlikely) -> map_page.isra.0 (section: .init.text)

With commit 4735037b5d9b ("openrisc: Add text patching API support") the __set_fixmap function was moved out of the .init.text section. However, the map_page helper that it uses was not moved. This was not noticed on gcc 15.1.0 where map_page gets inlined unlike [email protected] which uses gcc 10.5.0.

Fix this by also moving the map_page helper function out of the init section.

Fixes 4735037b5d9b ("openrisc: Add text patching API support")
---
 arch/openrisc/mm/init.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/openrisc/mm/init.c +1 -1
index 78fb0734cdbc..50aee0ea18b7 100644
@@ -196,7 +196,7 @@ void __init mem_init(void)
 	return;
 }
 
-static int __init map_page(unsigned long va, phys_addr_t pa, pgprot_t prot)
+static int map_page(unsigned long va, phys_addr_t pa, pgprot_t prot)
 {
 	p4d_t *p4d;
 	pud_t *pud;
Signature · 1 line
2.51.0