xen/tools: Fix symbols segfaults
PATCH 1/1 xen/tools: Fix symbols segfaults
The symbols tool is outdated and has a bug in it leading to crashes. The tool is derived from linux kernel where this bug has been already fixed.
Original linux kernel commit:e0a04b11e4059cab033469617 scripts/kallsyms.c: fix potential segfault
--- xen/tools/symbols.c | 2 ++ 1 file changed, 2 insertions(+)
xen/tools/symbols.c +2 -0
@@ -525,6 +525,8 @@ static void optimize_result(void)/* find the token with the breates profit value */ best =find_best_token (); +if (token_profit[best] ==0 ) +break ;/* place it in the "best" table */ best_table_len[i] =2 ;
Signature · 18 lines
2.16.5 Amazon Development Center Germany GmbH Krausenstr. 38 10117 Berlin Geschaeftsfuehrer: Christian Schlaeger, Ralf Herbrich Ust-ID: DE 289 237 879 Eingetragen am Amtsgericht Charlottenburg HRB 149173 B _______________________________________________ Xen-devel mailing list [email protected] https://lists.xenproject.org/mailman/listinfo/xen-devel
Quoted 4 lines
Quoted 1 line
Quoted 1 line · On 03.04.19 at 09:56, <[email protected]> wrote:
The symbols tool is outdated and has a bug in it leading to crashes. The tool is derived from linux kernel where this bug has been already fixed.
Thanks for noticing this omission of ours.
Quoted 6 lines
Original linux kernel commit:
e0a04b11e4059cab033469617scripts/kallsyms.c: fix potential segfaultSigned-off-by Pawel Wieczorkiewicz <[email protected]>Reviewed-by Bjoern Doebel <[email protected]>Reviewed-by Norbert Manthey <[email protected]>
When we pull in changes (almost) verbatim from Linux, we typically retain original authorship as well as the (possibly massaged) title and description. See xen/arch/x86/cpu/mwait-idle.c's history for some examples. I'll do this transformation before committing the change, but in the future I'd appreciate if ported patches were submitted that way.
I'm btw also confused by the Cc list you've used: You should have Cc-ed THE REST, not just the tool stack maintainers.
Jan
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
On 3. Apr 2019, at 10:10, Jan Beulich <[email protected]<mailto:[email protected]>> wrote:
On 03.04.19 at 09:56, <[email protected]<mailto:[email protected]>> wrote:
The symbols tool is outdated and has a bug in it leading to crashes. The tool is derived from linux kernel where this bug has been already fixed.
Thanks for noticing this omission of ours.
Anytime.
Original linux kernel commit:e0a04b11e4059cab033469617 scripts/kallsyms.c: fix potential segfault
When we pull in changes (almost) verbatim from Linux, we typically retain original authorship as well as the (possibly massaged) title and description. See xen/arch/x86/cpu/mwait-idle.c's history for some examples. I'll do this transformation before committing the change, but in the future I'd appreciate if ported patches were submitted that way.
Sure, I will be submitting patches that way.
It might make sense to add this explanation into the CONTRIBUTING file to avoid this problem in the future (unless it documented already somewhere and I simply missed it).
I'm btw also confused by the Cc list you've used: You should have Cc-ed THE REST, not just the tool stack maintainers.
You’re right. My bad. Sorry.
Jan
Best Regards,
Pawel Wieczorkiewicz
Amazon Development Center Germany GmbH Krausenstr. 38
10117 Berlin
Geschaeftsfuehrer: Christian Schlaeger, Ralf Herbrich
Ust-ID: DE 289 237 879
Eingetragen am Amtsgericht Charlottenburg HRB 149173 B
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
Quoted 5 lines · Pawel
I'm btw also confused by the Cc list you've used: You should have Cc-ed THE REST, not just the tool stack maintainers.
You’re right. My bad. Sorry.
./scripts/get_maintainers.pl is your friend. :-)
Wei.
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel