1 From 1ee05e874eaa3f03ee7b5fbd6a32dff7304bd620 Mon Sep 17 00:00:00 2001
2 From: Damjan Marion <damarion@cisco.com>
3 Date: Wed, 16 Dec 2015 03:29:22 +0100
4 Subject: [PATCH 3/6] virtio: Cleanup virtio pmd debug log output, reset
7 drivers/net/virtio/virtio_ethdev.c | 5 -----
8 drivers/net/virtio/virtio_rxtx.c | 4 +++-
9 2 files changed, 3 insertions(+), 6 deletions(-)
11 diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
12 index 63a368a..ed4e757 100644
13 --- a/drivers/net/virtio/virtio_ethdev.c
14 +++ b/drivers/net/virtio/virtio_ethdev.c
15 @@ -1405,18 +1405,13 @@ virtio_dev_link_update(struct rte_eth_dev *dev, __rte_unused int wait_to_complet
16 link.link_speed = SPEED_10G;
18 if (vtpci_with_feature(hw, VIRTIO_NET_F_STATUS)) {
19 - PMD_INIT_LOG(DEBUG, "Get link status from hw");
20 vtpci_read_dev_config(hw,
21 offsetof(struct virtio_net_config, status),
22 &status, sizeof(status));
23 if ((status & VIRTIO_NET_S_LINK_UP) == 0) {
24 link.link_status = ETH_LINK_DOWN;
25 - PMD_INIT_LOG(DEBUG, "Port %d is down",
26 - dev->data->port_id);
28 link.link_status = ETH_LINK_UP;
29 - PMD_INIT_LOG(DEBUG, "Port %d is up",
30 - dev->data->port_id);
33 link.link_status = ETH_LINK_UP;
34 diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
35 index ef21d8e..7fe14ad 100644
36 --- a/drivers/net/virtio/virtio_rxtx.c
37 +++ b/drivers/net/virtio/virtio_rxtx.c
38 @@ -643,6 +643,7 @@ virtio_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
40 rxm->pkt_len = (uint32_t)(len[i] - hdr_size);
41 rxm->data_len = (uint16_t)(len[i] - hdr_size);
46 @@ -760,6 +761,7 @@ virtio_recv_mergeable_pkts(void *rx_queue,
48 rxm->pkt_len = (uint32_t)(len[0] - hdr_size);
49 rxm->data_len = (uint16_t)(len[0] - hdr_size);
52 rxm->port = rxvq->port_id;
54 @@ -863,7 +865,7 @@ virtio_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)
55 if (unlikely(nb_pkts < 1))
58 - PMD_TX_LOG(DEBUG, "%d packets to xmit", nb_pkts);
59 + PMD_TX_LOG(DEBUG, "%d packets to xmit\n", nb_pkts);
60 nb_used = VIRTQUEUE_NUSED(txvq);