Revision e3f5ec2b hw/rtl8139.c

b/hw/rtl8139.c
790 790
#endif
791 791
}
792 792

  
793
static int rtl8139_can_receive(void *opaque)
793
static int rtl8139_can_receive(VLANClientState *vc)
794 794
{
795
    RTL8139State *s = opaque;
795
    RTL8139State *s = vc->opaque;
796 796
    int avail;
797 797

  
798 798
    /* Receive (drop) packets if card is disabled.  */
......
812 812
    }
813 813
}
814 814

  
815
static void rtl8139_do_receive(void *opaque, const uint8_t *buf, int size, int do_interrupt)
815
static void rtl8139_do_receive(VLANClientState *vc, const uint8_t *buf, int size, int do_interrupt)
816 816
{
817
    RTL8139State *s = opaque;
817
    RTL8139State *s = vc->opaque;
818 818

  
819 819
    uint32_t packet_header = 0;
820 820

  
......
1158 1158
    }
1159 1159
}
1160 1160

  
1161
static void rtl8139_receive(void *opaque, const uint8_t *buf, size_t size)
1161
static void rtl8139_receive(VLANClientState *vc, const uint8_t *buf, size_t size)
1162 1162
{
1163
    rtl8139_do_receive(opaque, buf, size, 1);
1163
    rtl8139_do_receive(vc, buf, size, 1);
1164 1164
}
1165 1165

  
1166 1166
static void rtl8139_reset_rxring(RTL8139State *s, uint32_t bufferSize)
......
1757 1757
    if (TxLoopBack == (s->TxConfig & TxLoopBack))
1758 1758
    {
1759 1759
        DEBUG_PRINT(("RTL8139: +++ transmit loopback mode\n"));
1760
        rtl8139_do_receive(s, buf, size, do_interrupt);
1760
        rtl8139_do_receive(s->vc, buf, size, do_interrupt);
1761 1761
    }
1762 1762
    else
1763 1763
    {

Also available in: Unified diff