mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
memory: Fix memory_region_wrong_endianness()
Since commit be675c9720 (memory: move
endianness compensation to memory core) it was checking for
TARGET_BIG_ENDIAN instead of TARGET_WORDS_BIGENDIAN, thereby not
swapping correctly for Big Endian targets.
Signed-off-by: Andreas Färber <afaerber@suse.de>
Reviewed-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Avi Kivity <avi@redhat.com>
This commit is contained in:
committed by
Avi Kivity
parent
6148b23d69
commit
2c3579ab07
@@ -843,7 +843,7 @@ static void memory_region_destructor_rom_device(MemoryRegion *mr)
|
||||
|
||||
static bool memory_region_wrong_endianness(MemoryRegion *mr)
|
||||
{
|
||||
#ifdef TARGET_BIG_ENDIAN
|
||||
#ifdef TARGET_WORDS_BIGENDIAN
|
||||
return mr->ops->endianness == DEVICE_LITTLE_ENDIAN;
|
||||
#else
|
||||
return mr->ops->endianness == DEVICE_BIG_ENDIAN;
|
||||
|
||||
Reference in New Issue
Block a user