[PATCH] MSP430: Support relocations for subtract expressions in .uleb128 directives
Nick Clifton
nickc@redhat.com
Thu Sep 3 14:41:59 GMT 2020
Hi Jozef,
I have a few questions/comments about this patch:
* Have these new relocations been agreed with TI ?
Ie are they now part of the MSP430 EABI ? If not, then
they probably ought to include "GNU" as part of their names...
* Paranoia here: The write_uleb128() function really should
take an end pointer parameter, and check to make sure that it
is not overwritten. I know that you do check the return pointer
in the code, but I would not be at all surprised that a fuzzed
MSP430 binary could persuade the new code to write beyond the
end of the section buffer.
Also the function should be renamed to _bfd_write_uleb128
(or something similar) and moved into bfd/elf-eh-frame.c.
It is a generic function after all, and should live with the
other LEB128 functions.
Other than that though the patch looks good to me.
Cheers
Nick
More information about the Binutils
mailing list