OSDN Git Service

ne2000: mark I/O as LITTLE_ENDIAN
authorAurelien Jarno <aurelien@aurel32.net>
Mon, 2 Sep 2013 11:10:34 +0000 (13:10 +0200)
committerStefan Hajnoczi <stefanha@redhat.com>
Fri, 6 Sep 2013 15:27:40 +0000 (17:27 +0200)
Now that the memory subsystem is propagating the endianness correctly,
the ne2000 device should have its I/O ports marked as LITTLE_ENDIAN, as
PCI devices are little endian.

This makes the ne2000 NIC to work again on PowerPC.

Cc: qemu-stable@nongnu.org
Cc: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
hw/net/ne2000.c

index 31afd28..c961258 100644 (file)
@@ -693,7 +693,7 @@ static void ne2000_write(void *opaque, hwaddr addr,
 static const MemoryRegionOps ne2000_ops = {
     .read = ne2000_read,
     .write = ne2000_write,
-    .endianness = DEVICE_NATIVE_ENDIAN,
+    .endianness = DEVICE_LITTLE_ENDIAN,
 };
 
 /***********************************************************/