diff options
author | Mark McLoughlin <markmc@redhat.com> | 2009-05-18 13:33:03 +0100 |
---|---|---|
committer | Mark McLoughlin <markmc@redhat.com> | 2009-06-09 11:38:49 +0100 |
commit | e3f5ec2b5e92706e3b807059f79b1fb5d936e567 (patch) | |
tree | e49989391834350755b1138d07ac3e464a5dbd6c /hw/eepro100.c | |
parent | cda9046ba7dbba45f3016e5d60caffa2d72960fa (diff) |
net: pass VLANClientState* as first arg to receive handlers
Give static type checking a chance to catch errors.
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Diffstat (limited to 'hw/eepro100.c')
-rw-r--r-- | hw/eepro100.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/hw/eepro100.c b/hw/eepro100.c index 39e8fccfbc..3300fbe9ea 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -1433,21 +1433,21 @@ static void pci_mmio_map(PCIDevice * pci_dev, int region_num, } } -static int nic_can_receive(void *opaque) +static int nic_can_receive(VLANClientState *vc) { - EEPRO100State *s = opaque; + EEPRO100State *s = vc->opaque; logout("%p\n", s); return get_ru_state(s) == ru_ready; //~ return !eepro100_buffer_full(s); } -static void nic_receive(void *opaque, const uint8_t * buf, size_t size) +static void nic_receive(VLANClientState *vc, const uint8_t * buf, size_t size) { /* TODO: * - Magic packets should set bit 30 in power management driver register. * - Interesting packets should set bit 29 in power management driver register. */ - EEPRO100State *s = opaque; + EEPRO100State *s = vc->opaque; uint16_t rfd_status = 0xa000; static const uint8_t broadcast_macaddr[6] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; |