X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=palacios%2Fsrc%2Fdevices%2Flnx_virtio_nic.c;h=37f8cc5a794eb1a21de037d2a292eb19584f3cc0;hb=c4fa59ab9c6963f1b7d8ab56718513070f92f768;hp=a2abb6e5f77fac821b298c947ebcb119d0c384a1;hpb=17f8752ad440dba7d414d0812e3680066dcb8c9e;p=palacios.git diff --git a/palacios/src/devices/lnx_virtio_nic.c b/palacios/src/devices/lnx_virtio_nic.c index a2abb6e..37f8cc5 100644 --- a/palacios/src/devices/lnx_virtio_nic.c +++ b/palacios/src/devices/lnx_virtio_nic.c @@ -37,7 +37,9 @@ #define PrintDebug(fmt, args...) #endif +#ifdef CONFIG_VNET_PROFILE #define VIRTIO_NIC_PROFILE +#endif #define VIRTIO_NET_S_LINK_UP 1 /* Link is up */ #define VIRTIO_NET_MAX_BUFSIZE (sizeof(struct virtio_net_hdr) + (64 << 10)) @@ -269,14 +271,7 @@ static int handle_pkt_tx(struct guest_info *core, struct virtio_net_state * virt uint64_t time; rdtscll(time); core->vnet_times.total_handle_time = time - core->vnet_times.virtio_handle_start; - - PrintError("Vnet_profiling: total_handle_time: %ld vnet_time: %ld copy_from_guest: %ld copy_to_guest: %ld malloc_free: %ld, route_lookup: %ld\n", - (long)core->vnet_times.total_handle_time, - (long)core->vnet_times.vnet_handle_time, - (long)core->vnet_times.time_copy_from_guest, - (long)core->vnet_times.time_copy_to_guest, - (long)core->vnet_times.time_mallocfree, - (long)core->vnet_times.time_route_lookup); + core->vnet_times.print = true; #endif return 0;