From: Mark McLoughlin <markmc@redhat.com>
To: Anthony Liguori <aliguori@us.ibm.com>
Cc: Jan Kiszka <jan.kiszka@siemens.com>,
qemu-devel@nongnu.org, Mark McLoughlin <markmc@redhat.com>
Subject: [Qemu-devel] [PATCH 6/9] Remove NICInfo from e1000 and mipsnet state
Date: Wed, 15 Apr 2009 17:29:26 +0100 [thread overview]
Message-ID: <1239812969-8320-7-git-send-email-markmc@redhat.com> (raw)
In-Reply-To: <1239812969-8320-6-git-send-email-markmc@redhat.com>
NICInfo isn't used after initialization, so remove it from the driver
state structures.
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
---
hw/e1000.c | 4 +---
hw/mipsnet.c | 4 +---
2 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/hw/e1000.c b/hw/e1000.c
index 1644201..2d16774 100644
--- a/hw/e1000.c
+++ b/hw/e1000.c
@@ -75,7 +75,6 @@ enum {
typedef struct E1000State_st {
PCIDevice dev;
VLANClientState *vc;
- NICInfo *nd;
int mmio_index;
uint32_t mac_reg[0x8000];
@@ -1078,7 +1077,6 @@ pci_e1000_init(PCIBus *bus, NICInfo *nd, int devfn)
pci_register_io_region((PCIDevice *)d, 1, IOPORT_SIZE,
PCI_ADDRESS_SPACE_IO, ioport_map);
- d->nd = nd;
memmove(d->eeprom_data, e1000_eeprom_template,
sizeof e1000_eeprom_template);
for (i = 0; i < 3; i++)
@@ -1099,7 +1097,7 @@ pci_e1000_init(PCIBus *bus, NICInfo *nd, int devfn)
e1000_receive, e1000_can_receive, d);
d->vc->link_status_changed = e1000_set_link_status;
- qemu_format_nic_info_str(d->vc, d->nd->macaddr);
+ qemu_format_nic_info_str(d->vc, nd->macaddr);
register_savevm(info_str, -1, 2, nic_save, nic_load, d);
d->dev.unregister = pci_e1000_uninit;
diff --git a/hw/mipsnet.c b/hw/mipsnet.c
index 29bd9b8..415b04e 100644
--- a/hw/mipsnet.c
+++ b/hw/mipsnet.c
@@ -35,7 +35,6 @@ typedef struct MIPSnetState {
uint8_t tx_buffer[MAX_ETH_FRAME_SIZE];
qemu_irq irq;
VLANClientState *vc;
- NICInfo *nd;
} MIPSnetState;
static void mipsnet_reset(MIPSnetState *s)
@@ -248,7 +247,6 @@ void mipsnet_init (int base, qemu_irq irq, NICInfo *nd)
register_ioport_read(base, 36, 4, mipsnet_ioport_read, s);
s->irq = irq;
- s->nd = nd;
if (nd && nd->vlan) {
s->vc = qemu_new_vlan_client(nd->vlan, nd->model, nd->name,
mipsnet_receive, mipsnet_can_receive, s);
@@ -256,7 +254,7 @@ void mipsnet_init (int base, qemu_irq irq, NICInfo *nd)
s->vc = NULL;
}
- qemu_format_nic_info_str(s->vc, s->nd->macaddr);
+ qemu_format_nic_info_str(s->vc, nd->macaddr);
mipsnet_reset(s);
register_savevm("mipsnet", 0, 0, mipsnet_save, mipsnet_load, s);
--
1.6.0.6
next prev parent reply other threads:[~2009-04-15 16:29 UTC|newest]
Thread overview: 60+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-15 16:29 [Qemu-devel] [PATCH 0/9] Misc networking fixes Mark McLoughlin
2009-04-15 16:29 ` [Qemu-devel] [PATCH 1/9] Remove stray GSO code from virtio_net Mark McLoughlin
2009-04-15 16:29 ` [Qemu-devel] [PATCH 2/9] struct iovec is now universally available Mark McLoughlin
2009-04-15 16:29 ` [Qemu-devel] [PATCH 3/9] Fix error handling in net_client_init() Mark McLoughlin
2009-04-15 16:29 ` [Qemu-devel] [PATCH 4/9] Don't fail PCI hotplug if no NIC model is supplied Mark McLoughlin
2009-04-15 16:29 ` [Qemu-devel] [PATCH 5/9] Remove some useless malloc() checking Mark McLoughlin
2009-04-15 16:29 ` Mark McLoughlin [this message]
2009-04-15 16:29 ` [Qemu-devel] [PATCH 7/9] Add unregister_savevm() Mark McLoughlin
2009-04-15 16:29 ` [Qemu-devel] [PATCH 8/9] Use NICInfo::model for eepro100 savevm ID string Mark McLoughlin
2009-04-15 16:29 ` [Qemu-devel] [PATCH 9/9] Introduce VLANClientState::cleanup() Mark McLoughlin
2009-04-15 17:34 ` [Qemu-devel] " Jan Kiszka
2009-04-16 1:07 ` Marcelo Tosatti
2009-04-16 3:24 ` M. Warner Losh
2009-04-16 14:49 ` Mark McLoughlin
2009-04-16 14:52 ` [Qemu-devel] [PATCH 09/09 v2] " Mark McLoughlin
2009-04-16 14:53 ` [Qemu-devel] [PATCH 10/09] Free VLANClientState using qemu_free() Mark McLoughlin
2009-04-16 20:44 ` [Qemu-devel] Re: [PATCH 9/9] Introduce VLANClientState::cleanup() Marcelo Tosatti
2009-04-28 12:08 ` Paul Brook
2009-04-28 16:46 ` Anthony Liguori
2009-04-28 17:17 ` Paul Brook
2009-04-28 17:25 ` Anthony Liguori
2009-04-28 17:46 ` Paul Brook
2009-04-28 17:49 ` Anthony Liguori
2009-04-28 18:28 ` Paul Brook
2009-04-28 21:38 ` Anthony Liguori
2009-04-29 10:37 ` Paul Brook
2009-04-30 13:45 ` Avi Kivity
2009-04-30 16:02 ` Paul Brook
2009-04-30 16:20 ` Avi Kivity
2009-04-30 16:31 ` Paul Brook
2009-04-30 16:32 ` Avi Kivity
2009-04-30 16:37 ` Anthony Liguori
2009-04-30 16:41 ` Anthony Liguori
2009-04-30 16:58 ` Paul Brook
2009-04-30 17:51 ` Avi Kivity
2009-04-30 16:33 ` Anthony Liguori
2009-04-30 16:32 ` Anthony Liguori
2009-04-30 16:57 ` Blue Swirl
2009-04-30 17:11 ` Anthony Liguori
2009-04-30 17:45 ` Jan Kiszka
2009-04-30 17:48 ` Avi Kivity
2009-04-30 18:17 ` Jan Kiszka
2009-04-30 18:19 ` Avi Kivity
2009-04-30 18:22 ` Anthony Liguori
2009-04-30 17:59 ` Anthony Liguori
2009-04-30 18:10 ` Blue Swirl
2009-04-30 18:20 ` Jan Kiszka
2009-04-30 18:32 ` Anthony Liguori
2009-04-30 18:57 ` Blue Swirl
2009-04-30 18:16 ` Jan Kiszka
2009-04-29 7:36 ` Markus Armbruster
2009-04-16 14:49 ` Mark McLoughlin
2009-04-15 17:13 ` [Qemu-devel] Re: [PATCH 5/9] Remove some useless malloc() checking Jan Kiszka
2009-04-15 16:55 ` [Qemu-devel] [PATCH 2/9] struct iovec is now universally available Christoph Hellwig
2009-04-15 17:25 ` Mark McLoughlin
2009-04-15 17:27 ` Christoph Hellwig
2009-04-15 21:18 ` François Revol
2009-04-15 21:52 ` M. Warner Losh
2009-04-15 17:44 ` M. Warner Losh
2009-04-17 18:06 ` [Qemu-devel] [PATCH 1/9] Remove stray GSO code from virtio_net Anthony Liguori
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1239812969-8320-7-git-send-email-markmc@redhat.com \
--to=markmc@redhat.com \
--cc=aliguori@us.ibm.com \
--cc=jan.kiszka@siemens.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).