ARM & scripts: fix kallsyms regression
Subsystems (3)
cover ARM & scripts: fix kallsyms regression
Hi,
These two patches fix the regression on !MMU by below commit:
f6537f2f0eba4eba("scripts/kallsyms: filter symbols not in kernel address space")
Thanks,
--
Ming Lei
PATCH 1/2 ARM: default PHYS_OFFSET if !MMU
From: Jonathan Austin <[email protected]>
Set CONFIG_PAGE_OFFSET as PHYS_OFFSET when !MMU so that we can keep CONFIG_PAGE_OFFSET same with PAGE_OFFSET.
This patch and patch 2/2 fix regression on !MMU by f6537f2f0eba4eba("scripts/kallsyms: filter symbols not in kernel address space")
--- arch/arm/Kconfig | 1 + 1 file changed, 1 insertion(+)
arch/arm/Kconfig +1 -0
@@ -1560,6 +1560,7 @@ endchoice config PAGE_OFFSET hex + default PHYS_OFFSET if !MMU default 0x40000000 if VMSPLIT_1G default 0x80000000 if VMSPLIT_2G default 0xC0000000
Signature · 1 line
1.7.9.5
Re: [PATCH 1/2] ARM: default PHYS_OFFSET if !MMU
Hi Ming,
Quoted 5 lines · Ming Lei
From: Jonathan Austin <[email protected]>
Set
CONFIG_PAGE_OFFSETasPHYS_OFFSETwhen !MMU so that we can keepCONFIG_PAGE_OFFSETsame withPAGE_OFFSET.
I'm not so sure about this commit message - I don't think it makes sense...Should it not be more like:
------->8-------
Subject: ARM: set PAGE_OFFSET = PHYS_OFFSET if !MMU
With !MMU we still set PAGE_OFFSET to 0xC0000000, which makes little sense and causes a regression on !MMU after f6537f2f0eba4eba ("scripts/kallsyms: filter symbols not kernel address space")
This patch sets PAGE_OFFSET to PHYS_OFFSET in the !MMU case, fixing the regression (Tested on Cortex-R7/Vexpress) --------8<---------
Russell: Will you pick this patch up from the list or does it need to go in through the patch system?
Jonny
Quoted 24 lines
This patch and patch 2/2 fix regression on !MMU by
f6537f2f0eba4eba("scripts/kallsyms: filter symbols not in kernel address space")Cc <[email protected]>Signed-off-by Jonathan Austin <[email protected]>Signed-off-by Ming Lei <[email protected]>--- arch/arm/Kconfig | 1 + 1 file changed, 1 insertion(+)arch/arm/Kconfig +1
-0@@ -1560,6 +1560,7 @@ endchoice config PAGE_OFFSET hex + default PHYS_OFFSET if !MMU default 0x40000000 if VMSPLIT_1G default 0x80000000 if VMSPLIT_2G default 0xC0000000
Re: [PATCH 1/2] ARM: default PHYS_OFFSET if !MMU
Quoted 15 lines · Jonathan Austin
Hi Ming,
Quoted 5 lines · Ming Lei
From: Jonathan Austin <[email protected]>
Set
CONFIG_PAGE_OFFSETasPHYS_OFFSETwhen !MMU so that we can keepCONFIG_PAGE_OFFSETsame withPAGE_OFFSET.I'm not so sure about this commit message - I don't think it makes sense...Should it not be more like:
------->8-------
Subject: ARM: setPAGE_OFFSET=PHYS_OFFSETif !MMU
Quoted 8 lines
With !MMU we still set
PAGE_OFFSETto0xC0000000, which makes little sense and causes a regression on !MMU afterf6537f2f0eba4eba("scripts/kallsyms: filter symbols not kernel address space")This patch sets
PAGE_OFFSETtoPHYS_OFFSETin the !MMU case, fixing the regression (Tested on Cortex-R7/Vexpress) --------8<---------
I like this commit log better, too.
As CONFIG_PAGE_OFFSET is only used in scripts/kallsyms.c and scripts/link-vmlinux.sh for !MMU.
Booting on efm32 with this patch works just fine, so if you want add my Tested-by. But I'm unsure how valuable it is as I don't see a breakage without it.
Best regards
Uwe
Signature · 2 lines
Pengutronix e.K. | Uwe Kleine-K?nig | Industrial Linux Solutions | http://www.pengutronix.de/ |
Re: [PATCH 1/2] ARM: default PHYS_OFFSET if !MMU
In reply to Jonathan AustinHi all,
Quoted 20 lines · Jonathan Austin
Hi Ming,
Quoted 5 lines · Ming Lei
From: Jonathan Austin <[email protected]>
Set
CONFIG_PAGE_OFFSETasPHYS_OFFSETwhen !MMU so that we can keepCONFIG_PAGE_OFFSETsame withPAGE_OFFSET.I'm not so sure about this commit message - I don't think it makes sense...Should it not be more like:
------->8-------
Subject: ARM: setPAGE_OFFSET=PHYS_OFFSETif !MMUWith !MMU we still set
PAGE_OFFSETto0xC0000000, which makes little sense and causes a regression on !MMU afterf6537f2f0eba4eba("scripts/kallsyms: filter symbols not kernel address space")
Quoted 6 lines
This patch sets
PAGE_OFFSETtoPHYS_OFFSETin the !MMU case, fixing the regression (Tested on Cortex-R7/Vexpress) --------8<---------Russell: Will you pick this patch up from the list or does it need to go in through the patch system?
What's the status of this patch? Shall I put it in the patch system with the commit message above? Or is it going via someone else?
Jonny
Quoted 35 lines
Jonny
Quoted 17 lines
This patch and patch 2/2 fix regression on !MMU by
f6537f2f0eba4eba("scripts/kallsyms: filter symbols not in kernel address space")Cc <[email protected]>Signed-off-by Jonathan Austin <[email protected]>Signed-off-by Ming Lei <[email protected]>--- arch/arm/Kconfig | 1 + 1 file changed, 1 insertion(+)arch/arm/Kconfig +0
-0arch/arm/Kconfig endchoice · line 1566
Quoted 7 lines
arch/arm/Kconfig +1
-0@@ -1560,6 +1560,7 @@ endchoice config PAGE_OFFSET hex + default PHYS_OFFSET if !MMU default 0x40000000 if VMSPLIT_1G default 0x80000000 if VMSPLIT_2G default 0xC0000000_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel at lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
PATCH 2/2 scripts/link-vmlinux.sh: only filter kernel symbols for arm
In reply to Ming LeiActually CONFIG_PAGE_OFFSET isn't same with PAGE_OFFSET, so it isn't easy to figue out PAGE_OFFSET defined in header file from scripts.
Because CONFIG_PAGE_OFFSET may not be defined in some ARCHs( 64bit ARCH), or defined as bogus value in !MMU case, so this patch only applys the filter on ARM when CONFIG_PAGE_OFFSET is defined as the original problem is only on ARM.
--- scripts/link-vmlinux.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
scripts/link-vmlinux.sh +3 -1
@@ -82,7 +82,9 @@ kallsyms() kallsymopt="${kallsymopt} --all-symbols" fi - kallsymopt="${kallsymopt} --page-offset=$CONFIG_PAGE_OFFSET" + if [ -n "${CONFIG_ARM}" ] && [ -n "${CONFIG_PAGE_OFFSET}" ]; then + kallsymopt="${kallsymopt} --page-offset=$CONFIG_PAGE_OFFSET" + fi local aflags="${KBUILD_AFLAGS} ${KBUILD_AFLAGS_KERNEL} \ ${NOSTDINC_FLAGS} ${LINUXINCLUDE} ${KBUILD_CPPFLAGS}"
Signature · 1 line
1.7.9.5