Submit physical address to is_phys_addr()
Subsystems (2)
PATCH 1/1 Submit physical address to is_phys_addr()
ELF program table virtual address is submitted to is_phys_addr() function, most likely as a leftover of replaced is_vmalloc_addr() function, as result of commit 2e452d75fa78 ("[PATCH v3] Enable --mem-usage for s390x."). Submit the physical address instead.
--- elf_info.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
elf_info.c +2 -2
@@ -765,7 +765,7 @@ int get_kcore_dump_loads(void)for (i =0 ; i < num_pt_loads; ++i) {struct pt_load_segment *p = &pt_loads[i];if (p->phys_start ==NOT_PADDR - || !is_phys_addr (p->virt_start)) + || !is_phys_addr (p->phys_start))continue ; loads++; }
@@ -786,7 +786,7 @@ int get_kcore_dump_loads(void)for (i =0 , j =0 ; i < num_pt_loads; ++i) {struct pt_load_segment *p = &pt_loads[i];if (p->phys_start ==NOT_PADDR - || !is_phys_addr (p->virt_start)) + || !is_phys_addr (p->phys_start))continue ;if (j >= loads) {free (pls);
Signature · 7 lines
2.43.0 _______________________________________________ kexec mailing list [email protected] http://lists.infradead.org/mailman/listinfo/kexec
Hi Alex,
Thanks for the patch.
Quoted 4 lines · Alexander Gordeev
ELF program table virtual address is submitted to
is_phys_addr()function, most likely as a leftover of replacedis_vmalloc_addr()function, as result of commit2e452d75fa78("[PATCH v3] Enable --mem-usage for s390x."). Submit the physical address instead.
If this leftover causes a failure, could you add the error and brief description about it to the commit log?
It looks like currently is_phys_addr() is used only by s390x, and the patch looks good to me.
Thanks,
Kazu
Quoted 20 lines
Signed-off-by Alexander Gordeev <[email protected]>--- elf_info.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)elf_info.c +1
-1@@ -765,7 +765,7 @@ int get_kcore_dump_loads(void)for (i =0 ; i < num_pt_loads; ++i) {struct pt_load_segment *p = &pt_loads[i];if (p->phys_start ==NOT_PADDR - || !is_phys_addr (p->virt_start)) + || !is_phys_addr (p->phys_start))continue ; loads++; }
elf_info.c int get_kcore_dump_loads(void) · line 792
Quoted 8 lines
elf_info.c +1
-1@@ -786,7 +786,7 @@ int get_kcore_dump_loads(void)for (i =0 , j =0 ; i < num_pt_loads; ++i) {struct pt_load_segment *p = &pt_loads[i];if (p->phys_start ==NOT_PADDR - || !is_phys_addr (p->virt_start)) + || !is_phys_addr (p->phys_start))continue ;if (j >= loads) {free (pls);
_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec
Hi Alexander,
Quoted 4 lines · On Fri, 13 Sep 2024 16:35:00 +0200 Alexander Gordeev <[email protected]>…
ELF program table virtual address is submitted to
is_phys_addr()function, most likely as a leftover of replacedis_vmalloc_addr()function, as result of commit2e452d75fa78("[PATCH v3] Enable --mem-usage for s390x."). Submit the physical address instead.
is the patch supposed to fix the bug with /proc/kcore I reported? I gave it a try on a KVM VM and it's still failing...
Thanks
Philipp
Quoted 19 lines
Signed-off-by Alexander Gordeev <[email protected]>--- elf_info.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)elf_info.c +1
-1@@ -765,7 +765,7 @@ int get_kcore_dump_loads(void)for (i =0 ; i < num_pt_loads; ++i) {struct pt_load_segment *p = &pt_loads[i];if (p->phys_start ==NOT_PADDR - || !is_phys_addr (p->virt_start)) + || !is_phys_addr (p->phys_start))continue ; loads++; }
elf_info.c int get_kcore_dump_loads(void) · line 792
Quoted 8 lines
elf_info.c +1
-1@@ -786,7 +786,7 @@ int get_kcore_dump_loads(void)for (i =0 , j =0 ; i < num_pt_loads; ++i) {struct pt_load_segment *p = &pt_loads[i];if (p->phys_start ==NOT_PADDR - || !is_phys_addr (p->virt_start)) + || !is_phys_addr (p->phys_start))continue ;if (j >= loads) {free (pls);
_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec
Quoted 1 line · Philipp Rudo
Hi Alexander,
Hi Philipp,
Quoted 10 lines
Quoted 4 lines · On Fri, 13 Sep 2024 16:35:00 +0200 Alexander Gordeev <[email protected]>…
ELF program table virtual address is submitted to
is_phys_addr()function, most likely as a leftover of replacedis_vmalloc_addr()function, as result of commit2e452d75fa78("[PATCH v3] Enable --mem-usage for s390x."). Submit the physical address instead.is the patch supposed to fix the bug with
/proc/kcoreI reported? I gave it a try on a KVM VM and it's still failing...
No, it fixes another issue.
Quoted 2 lines
Thanks
Philipp
Thank you for testing!
Thanks!
_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec