Hi Peters,

I got some strange results since this commit:

commit 9776f636455b6f0d9c14dce112242ed653f954b4
Author: Peter Crosthwaite <crosthwaitepe...@gmail.com>
Date:   Fri Mar 4 11:30:21 2016 +0000

    arm: boot: Support big-endian elfs

Support ARM big-endian ELF files in system-mode emulation. When loading an elf, determine the endianness mode expected by the elf, and set the
    relevant CPU state accordingly.

With this, big-endian modes are now fully supported via system-mode LE,
    so there is no need to restrict the elf loading to the TARGET
    endianness so the ifdeffery on TARGET_WORDS_BIGENDIAN goes away.

    Signed-off-by: Peter Crosthwaite <crosthwaite.pe...@gmail.com>
    Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>
    [PMM: fix typo in comments]
    Signed-off-by: Peter Maydell <peter.mayd...@linaro.org>

It seems that when I try to load a big endian image on a
Cortex-R5 it gets confused:
 * the instructions are fine it executes some code.
 * GDB address / insns are wrong endianness.
 * in monitor x command is good endianness.
 * the data order seems to be wrong endianness:
   Here is my Hello World: lleHlroW

We used to add a armeb-softmmu/qemu-system-armeb target for the
big endian cpu but it doesn't work anymore as it's double
reversed by the elf endianness (data_swab <= 2).

And I'm surprised we don't set the CPSR_E and SCTLR_EE bits


Reply via email to