Taras Kondratiuk 41b5368f31 ARM: kprobes-test: Workaround GAS .align bug
By default if no fill symbol is given to .align directive in a code
section it fills gap with NOPs. If previous fragment is not
instruction-aligned, additional pre-alignment is done by zero bytes
before NOPs. These zero bytes are marked as data by special symbol $d in
symbol table. Unfortunately GAS assumes that there is only code in the
code section so it "puts back" code symbol $a at the end of this
pre-alignment. So if there is some data after alignment it will be
interpreted as code and will be swapped back to LE for BE8 system during
a final linking.

If explicit fill value is given to .align, the NOP-padding code is
skipped and symbol table does not get messed-up.

So the workaround for this issue:
Use explicit fill value if data should be aligned in the code section.

Acked-by: Ben Dooks <ben.dooks@codethink.co.uk>
Acked-by: Jon Medhurst <tixy@linaro.org>
Signed-off-by: Taras Kondratiuk <taras.kondratiuk@linaro.org>
2014-04-01 16:48:27 +03:00
..
2014-02-23 17:38:04 -08:00
2014-01-23 18:40:49 -08:00
2014-01-05 13:59:56 +00:00
2014-03-18 16:39:40 -04:00
2014-01-23 18:49:36 -08:00
2013-11-25 14:24:28 -08:00
2014-01-23 18:49:36 -08:00
2013-11-11 17:34:56 +09:00
2014-01-23 18:36:55 -08:00
2014-01-23 18:36:55 -08:00
2013-11-16 12:21:40 -08:00
2014-02-23 17:38:04 -08:00
2014-01-23 18:45:38 -08:00
2014-01-15 17:02:08 -08:00
2013-12-11 17:32:41 -08:00
2014-01-28 18:56:37 -08:00
2014-03-18 16:39:40 -04:00