A bug in crt0.S prevents overriding the values of __stack,
hardware_init_hook, and software_init_hook by linker scripts or program
code.
In the libgloss/arm/crt0.S startup the symbols __stack,
hardware_init_hook, software_init_hook are set with '.set <symbol>,0'.
Using '.set' causes the linker to emit a relocation against *ABS*, and
therefore the value cannot be overriden in a linker script or program.
A weak reference that remains unresolved will be given a value of zero,
giving the desired behaviour.
This patch removes the '.set' for __stack, hardware_init_hook, and
software_init_hook, allowing the linker script to override the value if
required.
Tested on arm-none-eabi without regressions.
Please apply.
Cheers,
Carlos.