aboutsummaryrefslogtreecommitdiff
path: root/hw/net/rtl8139.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/net/rtl8139.c')
-rw-r--r--hw/net/rtl8139.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c
index c31199f8c8..3225f3d3e5 100644
--- a/hw/net/rtl8139.c
+++ b/hw/net/rtl8139.c
@@ -1214,6 +1214,7 @@ static void rtl8139_reset(DeviceState *d)
/* restore MAC address */
memcpy(s->phys, s->conf.macaddr.a, 6);
+ qemu_format_nic_info_str(qemu_get_queue(s->nic), s->phys);
/* reset interrupt mask */
s->IntrStatus = 0;
@@ -2740,8 +2741,12 @@ static void rtl8139_io_writeb(void *opaque, uint8_t addr, uint32_t val)
switch (addr)
{
- case MAC0 ... MAC0+5:
+ case MAC0 ... MAC0+4:
+ s->phys[addr - MAC0] = val;
+ break;
+ case MAC0+5:
s->phys[addr - MAC0] = val;
+ qemu_format_nic_info_str(qemu_get_queue(s->nic), s->phys);
break;
case MAC0+6 ... MAC0+7:
/* reserved */