aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2009-06-08 14:33:25 +0200
committerBlue Swirl <blauwirbel@gmail.com>2009-06-08 20:01:23 +0300
commit7105b056583186a8e18d0da46e4e8db46592f0ab (patch)
tree7ec3df90438c0a99a1c5eec521b9215e8da5f487 /hw
parent168ccc11c323af885de353d9e045c0c1f78f6f2f (diff)
xen nic: use qemu_malloc
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r--hw/xen_nic.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/xen_nic.c b/hw/xen_nic.c
index 048d86568b..5fcc701904 100644
--- a/hw/xen_nic.c
+++ b/hw/xen_nic.c
@@ -176,7 +176,7 @@ static void net_tx_packets(struct XenNetDev *netdev)
if (txreq.flags & NETTXF_csum_blank) {
/* have read-only mapping -> can't fill checksum in-place */
if (!tmpbuf)
- tmpbuf = malloc(PAGE_SIZE);
+ tmpbuf = qemu_malloc(PAGE_SIZE);
memcpy(tmpbuf, page + txreq.offset, txreq.size);
net_checksum_calculate(tmpbuf, txreq.size);
qemu_send_packet(netdev->vs, tmpbuf, txreq.size);
@@ -190,7 +190,7 @@ static void net_tx_packets(struct XenNetDev *netdev)
break;
netdev->tx_work = 0;
}
- free(tmpbuf);
+ qemu_free(tmpbuf);
}
/* ------------------------------------------------------------- */