aboutsummaryrefslogtreecommitdiff
path: root/hw/xen_nic.c
diff options
context:
space:
mode:
authorMark McLoughlin <markmc@redhat.com>2009-05-18 13:13:16 +0100
committerMark McLoughlin <markmc@redhat.com>2009-06-09 11:38:49 +0100
commitcda9046ba7dbba45f3016e5d60caffa2d72960fa (patch)
treeda29fa06d782170b8214be44382549735eafa3b3 /hw/xen_nic.c
parent463af5349a787160642f023dad10eaf0cb419fb7 (diff)
downloadqemu-cda9046ba7dbba45f3016e5d60caffa2d72960fa.zip
qemu-cda9046ba7dbba45f3016e5d60caffa2d72960fa.tar.gz
qemu-cda9046ba7dbba45f3016e5d60caffa2d72960fa.tar.bz2
net: re-name vc->fd_read() to vc->receive()
VLANClientState's fd_read() handler doesn't read from file descriptors, it adds a buffer to the client's receive queue. Re-name the handlers to make things a little less confusing. Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Diffstat (limited to 'hw/xen_nic.c')
-rw-r--r--hw/xen_nic.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/hw/xen_nic.c b/hw/xen_nic.c
index 350556e..0643e57 100644
--- a/hw/xen_nic.c
+++ b/hw/xen_nic.c
@@ -243,7 +243,7 @@ static int net_rx_ok(void *opaque)
return 1;
}
-static void net_rx_packet(void *opaque, const uint8_t *buf, int size)
+static void net_rx_packet(void *opaque, const uint8_t *buf, size_t size)
{
struct XenNetDev *netdev = opaque;
netif_rx_request_t rxreq;
@@ -262,8 +262,8 @@ static void net_rx_packet(void *opaque, const uint8_t *buf, int size)
return;
}
if (size > XC_PAGE_SIZE - NET_IP_ALIGN) {
- xen_be_printf(&netdev->xendev, 0, "packet too big (%d > %ld)",
- size, XC_PAGE_SIZE - NET_IP_ALIGN);
+ xen_be_printf(&netdev->xendev, 0, "packet too big (%lu > %ld)",
+ (unsigned long)size, XC_PAGE_SIZE - NET_IP_ALIGN);
return;
}