aboutsummaryrefslogtreecommitdiff
path: root/hw/gumstix.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/gumstix.c')
-rw-r--r--hw/gumstix.c20
1 files changed, 16 insertions, 4 deletions
diff --git a/hw/gumstix.c b/hw/gumstix.c
index 8fbf64c0f3..3fd31f4bfc 100644
--- a/hw/gumstix.c
+++ b/hw/gumstix.c
@@ -48,6 +48,7 @@ static void connex_init(ram_addr_t ram_size,
{
PXA2xxState *cpu;
DriveInfo *dinfo;
+ int be;
uint32_t connex_rom = 0x01000000;
uint32_t connex_ram = 0x04000000;
@@ -61,9 +62,14 @@ static void connex_init(ram_addr_t ram_size,
exit(1);
}
+#ifdef TARGET_WORDS_BIGENDIAN
+ be = 1;
+#else
+ be = 0;
+#endif
if (!pflash_cfi01_register(0x00000000, qemu_ram_alloc(connex_rom),
- dinfo->bdrv, sector_len, connex_rom / sector_len,
- 2, 0, 0, 0, 0)) {
+ dinfo->bdrv, sector_len, connex_rom / sector_len,
+ 2, 0, 0, 0, 0, be)) {
fprintf(stderr, "qemu: Error registering flash memory.\n");
exit(1);
}
@@ -82,6 +88,7 @@ static void verdex_init(ram_addr_t ram_size,
{
PXA2xxState *cpu;
DriveInfo *dinfo;
+ int be;
uint32_t verdex_rom = 0x02000000;
uint32_t verdex_ram = 0x10000000;
@@ -95,9 +102,14 @@ static void verdex_init(ram_addr_t ram_size,
exit(1);
}
+#ifdef TARGET_WORDS_BIGENDIAN
+ be = 1;
+#else
+ be = 0;
+#endif
if (!pflash_cfi01_register(0x00000000, qemu_ram_alloc(verdex_rom),
- dinfo->bdrv, sector_len, verdex_rom / sector_len,
- 2, 0, 0, 0, 0)) {
+ dinfo->bdrv, sector_len, verdex_rom / sector_len,
+ 2, 0, 0, 0, 0, be)) {
fprintf(stderr, "qemu: Error registering flash memory.\n");
exit(1);
}