diff mbox

[v4,03/10] net: various devices: add qemu_format_nic_info_dict

Message ID 1274202469-9332-4-git-send-email-miguel.filho@gmail.com
State New
Headers show

Commit Message

Miguel Di Ciurcio Filho May 18, 2010, 5:07 p.m. UTC
These are simple one line additions of qemu_format_nic_info_dict.

Signed-off-by: Miguel Di Ciurcio Filho <miguel.filho@gmail.com>
---
 hw/dp8393x.c        |    1 +
 hw/e1000.c          |    1 +
 hw/eepro100.c       |    2 ++
 hw/lan9118.c        |    2 ++
 hw/mcf_fec.c        |    1 +
 hw/mipsnet.c        |    1 +
 hw/ne2000-isa.c     |    1 +
 hw/ne2000.c         |    1 +
 hw/pcnet.c          |    1 +
 hw/rtl8139.c        |    1 +
 hw/smc91c111.c      |    1 +
 hw/stellaris_enet.c |    1 +
 hw/usb-net.c        |    1 +
 hw/virtio-net.c     |    2 ++
 hw/xilinx_ethlite.c |    1 +
 15 files changed, 18 insertions(+), 0 deletions(-)
diff mbox

Patch

diff --git a/hw/dp8393x.c b/hw/dp8393x.c
index e65e4d1..31fb1cb 100644
--- a/hw/dp8393x.c
+++ b/hw/dp8393x.c
@@ -905,6 +905,7 @@  void dp83932_init(NICInfo *nd, target_phys_addr_t base, int it_shift,
     s->nic = qemu_new_nic(&net_dp83932_info, &s->conf, nd->model, nd->name, s);
 
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
     qemu_register_reset(nic_reset, s);
     nic_reset(s);
 
diff --git a/hw/e1000.c b/hw/e1000.c
index 34cc451..faee35c 100644
--- a/hw/e1000.c
+++ b/hw/e1000.c
@@ -1126,6 +1126,7 @@  static int pci_e1000_init(PCIDevice *pci_dev)
                           d->dev.qdev.info->name, d->dev.qdev.id, d);
 
     qemu_format_nic_info_str(&d->nic->nc, macaddr);
+    qemu_format_nic_info_dict(&d->nic->nc, macaddr);
     return 0;
 }
 
diff --git a/hw/eepro100.c b/hw/eepro100.c
index a74d834..bd210ff 100644
--- a/hw/eepro100.c
+++ b/hw/eepro100.c
@@ -1887,6 +1887,8 @@  static int e100_nic_init(PCIDevice *pci_dev)
                           pci_dev->qdev.info->name, pci_dev->qdev.id, s);
 
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
+
     TRACE(OTHER, logout("%s\n", s->nic->nc.info_str));
 
     qemu_register_reset(nic_reset, s);
diff --git a/hw/lan9118.c b/hw/lan9118.c
index 16d3330..c392666 100644
--- a/hw/lan9118.c
+++ b/hw/lan9118.c
@@ -233,6 +233,7 @@  static void lan9118_update(lan9118_state *s)
 static void lan9118_mac_changed(lan9118_state *s)
 {
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
 }
 
 static void lan9118_reload_eeprom(lan9118_state *s)
@@ -1131,6 +1132,7 @@  static int lan9118_init1(SysBusDevice *dev)
     s->nic = qemu_new_nic(&net_lan9118_info, &s->conf,
                           dev->qdev.info->name, dev->qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
     s->eeprom[0] = 0xa5;
     for (i = 0; i < 6; i++) {
         s->eeprom[i + 1] = s->conf.macaddr.a[i];
diff --git a/hw/mcf_fec.c b/hw/mcf_fec.c
index 4e7fbed..1d3e280 100644
--- a/hw/mcf_fec.c
+++ b/hw/mcf_fec.c
@@ -477,4 +477,5 @@  void mcf_fec_init(NICInfo *nd, target_phys_addr_t base, qemu_irq *irq)
     s->nic = qemu_new_nic(&net_mcf_fec_info, &s->conf, nd->model, nd->name, s);
 
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
 }
diff --git a/hw/mipsnet.c b/hw/mipsnet.c
index a066f63..9134fd0 100644
--- a/hw/mipsnet.c
+++ b/hw/mipsnet.c
@@ -281,6 +281,7 @@  void mipsnet_init (int base, qemu_irq irq, NICInfo *nd)
                               nd->model, nd->name, s);
 
         qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+        qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
     }
 
     mipsnet_reset(s);
diff --git a/hw/ne2000-isa.c b/hw/ne2000-isa.c
index 03a5a1f..3cc2503 100644
--- a/hw/ne2000-isa.c
+++ b/hw/ne2000-isa.c
@@ -85,6 +85,7 @@  static int isa_ne2000_initfn(ISADevice *dev)
     s->nic = qemu_new_nic(&net_ne2000_isa_info, &s->c,
                           dev->qdev.info->name, dev->qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->c.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->c.macaddr.a);
 
     return 0;
 }
diff --git a/hw/ne2000.c b/hw/ne2000.c
index 78fe14f..fb92c8b 100644
--- a/hw/ne2000.c
+++ b/hw/ne2000.c
@@ -738,6 +738,7 @@  static int pci_ne2000_init(PCIDevice *pci_dev)
     s->nic = qemu_new_nic(&net_ne2000_info, &s->c,
                           pci_dev->qdev.info->name, pci_dev->qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->c.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->c.macaddr.a);
 
     if (!pci_dev->qdev.hotplugged) {
         static int loaded = 0;
diff --git a/hw/pcnet.c b/hw/pcnet.c
index 5e63eb5..5356ab4 100644
--- a/hw/pcnet.c
+++ b/hw/pcnet.c
@@ -1898,6 +1898,7 @@  int pcnet_common_init(DeviceState *dev, PCNetState *s, NetClientInfo *info)
     qemu_macaddr_default_if_unset(&s->conf.macaddr);
     s->nic = qemu_new_nic(info, &s->conf, dev->info->name, dev->id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
     return 0;
 }
 
diff --git a/hw/rtl8139.c b/hw/rtl8139.c
index 72e2242..a5cd1fb 100644
--- a/hw/rtl8139.c
+++ b/hw/rtl8139.c
@@ -3383,6 +3383,7 @@  static int pci_rtl8139_init(PCIDevice *dev)
     s->nic = qemu_new_nic(&net_rtl8139_info, &s->conf,
                           dev->qdev.info->name, dev->qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
 
     s->cplus_txbuffer = NULL;
     s->cplus_txbuffer_len = 0;
diff --git a/hw/smc91c111.c b/hw/smc91c111.c
index f7d58e1..d62a5fd 100644
--- a/hw/smc91c111.c
+++ b/hw/smc91c111.c
@@ -729,6 +729,7 @@  static int smc91c111_init1(SysBusDevice *dev)
     s->nic = qemu_new_nic(&net_smc91c111_info, &s->conf,
                           dev->qdev.info->name, dev->qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
     /* ??? Save/restore.  */
     return 0;
 }
diff --git a/hw/stellaris_enet.c b/hw/stellaris_enet.c
index d1d755e..fec9470 100644
--- a/hw/stellaris_enet.c
+++ b/hw/stellaris_enet.c
@@ -417,6 +417,7 @@  static int stellaris_enet_init(SysBusDevice *dev)
     s->nic = qemu_new_nic(&net_stellaris_enet_info, &s->conf,
                           dev->qdev.info->name, dev->qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
 
     stellaris_enet_reset(s);
     register_savevm("stellaris_enet", -1, 1,
diff --git a/hw/usb-net.c b/hw/usb-net.c
index a43bd17..9dacaaa 100644
--- a/hw/usb-net.c
+++ b/hw/usb-net.c
@@ -1454,6 +1454,7 @@  static int usb_net_initfn(USBDevice *dev)
     s->nic = qemu_new_nic(&net_usbnet_info, &s->conf,
                           s->dev.qdev.info->name, s->dev.qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
     snprintf(s->usbstring_mac, sizeof(s->usbstring_mac),
              "%02x%02x%02x%02x%02x%02x",
              0x40,
diff --git a/hw/virtio-net.c b/hw/virtio-net.c
index d602c56..e70c05c 100644
--- a/hw/virtio-net.c
+++ b/hw/virtio-net.c
@@ -91,6 +91,7 @@  static void virtio_net_set_config(VirtIODevice *vdev, const uint8_t *config)
     if (memcmp(netcfg.mac, n->mac, ETH_ALEN)) {
         memcpy(n->mac, netcfg.mac, ETH_ALEN);
         qemu_format_nic_info_str(&n->nic->nc, n->mac);
+        qemu_format_nic_info_dict(&n->nic->nc, n->mac);
     }
 }
 
@@ -911,6 +912,7 @@  VirtIODevice *virtio_net_init(DeviceState *dev, NICConf *conf)
     n->nic = qemu_new_nic(&net_virtio_info, conf, dev->info->name, dev->id, n);
 
     qemu_format_nic_info_str(&n->nic->nc, conf->macaddr.a);
+    qemu_format_nic_info_dict(&n->nic->nc, conf->macaddr.a);
 
     n->tx_timer = qemu_new_timer(vm_clock, virtio_net_tx_timer, n);
     n->tx_timer_active = 0;
diff --git a/hw/xilinx_ethlite.c b/hw/xilinx_ethlite.c
index 37e33ec..ea4fb96 100644
--- a/hw/xilinx_ethlite.c
+++ b/hw/xilinx_ethlite.c
@@ -231,6 +231,7 @@  static int xilinx_ethlite_init(SysBusDevice *dev)
     s->nic = qemu_new_nic(&net_xilinx_ethlite_info, &s->conf,
                           dev->qdev.info->name, dev->qdev.id, s);
     qemu_format_nic_info_str(&s->nic->nc, s->conf.macaddr.a);
+    qemu_format_nic_info_dict(&s->nic->nc, s->conf.macaddr.a);
     return 0;
 }