diff --git a/hw/dp8393x.c b/hw/dp8393x.c index 5622170a08610cc7c828030e78fc2c6b8d34d04f..ae8b16e310b314c86c661f85c32254e30af487d3 100644 --- a/hw/dp8393x.c +++ b/hw/dp8393x.c @@ -892,7 +892,7 @@ void dp83932_init(NICInfo *nd, target_phys_addr_t base, int it_shift, s->vc = nd->vc = qemu_new_vlan_client(NET_CLIENT_TYPE_NIC, nd->vlan, nd->netdev, nd->model, nd->name, - nic_can_receive, nic_receive, NULL, + nic_can_receive, nic_receive, NULL, NULL, nic_cleanup, s); qemu_format_nic_info_str(s->vc, nd->macaddr); diff --git a/hw/etraxfs_eth.c b/hw/etraxfs_eth.c index 2a583a3cb0bc46d65f3b33befeeaadc5986ecefa..ffe708253ed6bb10b20ff36281317f899e07a632 100644 --- a/hw/etraxfs_eth.c +++ b/hw/etraxfs_eth.c @@ -594,7 +594,7 @@ void *etraxfs_eth_init(NICInfo *nd, target_phys_addr_t base, int phyaddr) nd->vlan, nd->netdev, nd->model, nd->name, eth_can_receive, eth_receive, - NULL, eth_cleanup, eth); + NULL, NULL, eth_cleanup, eth); eth->vc->opaque = eth; eth->vc->link_status_changed = eth_set_link; diff --git a/hw/mcf_fec.c b/hw/mcf_fec.c index 0567bcdcd4e518757a0b72478e4409c6c99c1dad..9f0d0f4cb3700af2626f823b55916c293af231a3 100644 --- a/hw/mcf_fec.c +++ b/hw/mcf_fec.c @@ -466,7 +466,7 @@ void mcf_fec_init(NICInfo *nd, target_phys_addr_t base, qemu_irq *irq) nd->vlan, nd->netdev, nd->model, nd->name, mcf_fec_can_receive, mcf_fec_receive, - NULL, mcf_fec_cleanup, s); + NULL, NULL, mcf_fec_cleanup, s); memcpy(s->macaddr, nd->macaddr, 6); qemu_format_nic_info_str(s->vc, s->macaddr); } diff --git a/hw/mipsnet.c b/hw/mipsnet.c index d32099f6649ea92ae73d6ae97b16ad6001a1123b..65e1d5960abffd1a3d3d035174020b1876410eaf 100644 --- a/hw/mipsnet.c +++ b/hw/mipsnet.c @@ -267,7 +267,7 @@ void mipsnet_init (int base, qemu_irq irq, NICInfo *nd) nd->vlan, nd->netdev, nd->model, nd->name, mipsnet_can_receive, mipsnet_receive, - NULL, mipsnet_cleanup, s); + NULL, NULL, mipsnet_cleanup, s); } else { s->vc = NULL; } diff --git a/hw/usb-net.c b/hw/usb-net.c index 239381285858f75f565a22b8db898e5ed7062cbb..9c6549c75d05a0c871ab9da530fcd1ffd4b4c0b2 100644 --- a/hw/usb-net.c +++ b/hw/usb-net.c @@ -1465,7 +1465,7 @@ USBDevice *usb_net_init(NICInfo *nd) nd->model, nd->name, usbnet_can_receive, usbnet_receive, - NULL, + NULL, NULL, usbnet_cleanup, s); qemu_format_nic_info_str(s->vc, s->mac); diff --git a/hw/xen_nic.c b/hw/xen_nic.c index 2a179f089368ffed3b7f624049a99402226e71de..75599d6744b429f2c981bea899df159cc34b6744 100644 --- a/hw/xen_nic.c +++ b/hw/xen_nic.c @@ -303,7 +303,7 @@ static int net_init(struct XenDevice *xendev) vlan = qemu_find_vlan(netdev->xendev.dev, 1); netdev->vs = qemu_new_vlan_client(NET_CLIENT_TYPE_NIC, vlan, NULL, "xen", NULL, - net_rx_ok, net_rx_packet, NULL, + net_rx_ok, net_rx_packet, NULL, NULL, NULL, netdev); snprintf(netdev->vs->info_str, sizeof(netdev->vs->info_str), "nic: xenbus vif macaddr=%s", netdev->mac); diff --git a/net.c b/net.c index d950029a2df37ebe64ada00833c20e31605e735c..31288352ed096b98f383c5496b22ee9a2b7a2128 100644 --- a/net.c +++ b/net.c @@ -334,6 +334,7 @@ VLANClientState *qemu_new_vlan_client(net_client_type type, const char *name, NetCanReceive *can_receive, NetReceive *receive, + NetReceive *receive_raw, NetReceiveIOV *receive_iov, NetCleanup *cleanup, void *opaque) @@ -350,6 +351,7 @@ VLANClientState *qemu_new_vlan_client(net_client_type type, vc->name = assign_name(vc, model); vc->can_receive = can_receive; vc->receive = receive; + vc->receive_raw = receive_raw; vc->receive_iov = receive_iov; vc->cleanup = cleanup; vc->opaque = opaque; @@ -915,7 +917,7 @@ static int net_slirp_init(VLANState *vlan, const char *model, s->vc = qemu_new_vlan_client(NET_CLIENT_TYPE_SLIRP, vlan, NULL, model, name, NULL, - slirp_receive, NULL, + slirp_receive, NULL, NULL, net_slirp_cleanup, s); snprintf(s->vc->info_str, sizeof(s->vc->info_str), "net=%s, restricted=%c", inet_ntoa(net), restricted ? 'y' : 'n'); @@ -1553,7 +1555,7 @@ static TAPState *net_tap_fd_init(VLANState *vlan, s->using_vnet_hdr = 0; s->vc = qemu_new_vlan_client(NET_CLIENT_TYPE_TAP, vlan, NULL, model, name, NULL, - tap_receive, tap_receive_iov, + tap_receive, NULL, tap_receive_iov, tap_cleanup, s); tap_read_poll(s, 1); return s; @@ -1913,7 +1915,7 @@ static int net_vde_init(VLANState *vlan, const char *model, } s->vc = qemu_new_vlan_client(NET_CLIENT_TYPE_VDE, vlan, NULL, model, name, NULL, - vde_receive, NULL, + vde_receive, NULL, NULL, vde_cleanup, s); qemu_set_fd_handler(vde_datafd(s->vde), vde_to_qemu, NULL, s); snprintf(s->vc->info_str, sizeof(s->vc->info_str), "sock=%s,fd=%d", @@ -2154,7 +2156,7 @@ static NetSocketState *net_socket_fd_init_dgram(VLANState *vlan, s->vc = qemu_new_vlan_client(NET_CLIENT_TYPE_SOCKET, vlan, NULL, model, name, NULL, - net_socket_receive_dgram, NULL, + net_socket_receive_dgram, NULL, NULL, net_socket_cleanup, s); qemu_set_fd_handler(s->fd, net_socket_send_dgram, NULL, s); @@ -2184,7 +2186,7 @@ static NetSocketState *net_socket_fd_init_stream(VLANState *vlan, s->fd = fd; s->vc = qemu_new_vlan_client(NET_CLIENT_TYPE_SOCKET, vlan, NULL, model, name, NULL, - net_socket_receive, NULL, + net_socket_receive, NULL, NULL, net_socket_cleanup, s); snprintf(s->vc->info_str, sizeof(s->vc->info_str), "socket: fd=%d", fd); @@ -2467,7 +2469,7 @@ static int net_dump_init(VLANState *vlan, const char *device, s->pcap_vc = qemu_new_vlan_client(NET_CLIENT_TYPE_DUMP, vlan, NULL, device, name, NULL, - dump_receive, NULL, + dump_receive, NULL, NULL, net_dump_cleanup, s); snprintf(s->pcap_vc->info_str, sizeof(s->pcap_vc->info_str), "dump to %s (len=%d)", filename, len); diff --git a/net.h b/net.h index 489266ba791478c7cc7f53939997e5d82ddfc8b7..e0adc69660829aa0ada341d9827f1e9a8a07dae8 100644 --- a/net.h +++ b/net.h @@ -79,6 +79,7 @@ VLANClientState *qemu_new_vlan_client(VLANState *vlan, const char *name, NetCanReceive *can_receive, NetReceive *receive, + NetReceive *receive_raw, NetReceiveIOV *receive_iov, NetCleanup *cleanup, void *opaque); diff --git a/tap-win32.c b/tap-win32.c index e2bac3e448a28b7f53130b051c0b9fee79899400..7d92df2aa3e5896ecc890d1a69d96208113ce612 100644 --- a/tap-win32.c +++ b/tap-win32.c @@ -680,7 +680,7 @@ int tap_win32_init(VLANState *vlan, const char *model, s->vc = qemu_new_vlan_client(NET_CLIENT_TYPE_TAP, vlan, NULL, model, name, NULL, tap_receive, - NULL, tap_cleanup, s); + NULL, NULL, tap_cleanup, s); snprintf(s->vc->info_str, sizeof(s->vc->info_str), "tap: ifname=%s", ifname);