aboutsummaryrefslogtreecommitdiff
path: root/hw/eepro100.c
diff options
context:
space:
mode:
authorStefan Weil <weil@mail.berlios.de>2010-04-06 13:44:08 +0200
committerMichael S. Tsirkin <mst@redhat.com>2010-04-07 10:58:00 +0300
commit269eba077104df9b4d6faedb4da1c2aa978e2b1d (patch)
tree5abe6556cf5b788b8ad06a981faa32f5c1d6bb91 /hw/eepro100.c
parentae543b498ca75aee6cadd67cb308501f5f267418 (diff)
eepro100: fix mapping of flash memory
Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/eepro100.c')
-rw-r--r--hw/eepro100.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/hw/eepro100.c b/hw/eepro100.c
index c7059296bb..949ca4ed2a 100644
--- a/hw/eepro100.c
+++ b/hw/eepro100.c
@@ -1621,11 +1621,11 @@ static void pci_mmio_map(PCIDevice * pci_dev, int region_num,
"size=0x%08"FMT_PCIBUS", type=%d\n",
region_num, addr, size, type));
- if (region_num == 0) {
- /* Map control / status registers. */
- cpu_register_physical_memory(addr, size, s->mmio_index);
- s->region[region_num] = addr;
- }
+ assert(region_num == 0 || region_num == 2);
+
+ /* Map control / status registers and flash. */
+ cpu_register_physical_memory(addr, size, s->mmio_index);
+ s->region[region_num] = addr;
}
static int nic_can_receive(VLANClientState *nc)