aboutsummaryrefslogtreecommitdiffstats
path: root/dpdk/dpdk-2.1.0_patches/0006-virtio-Cleanup-virtio-pmd-debug-log-output-reset-off.patch
diff options
context:
space:
mode:
Diffstat (limited to 'dpdk/dpdk-2.1.0_patches/0006-virtio-Cleanup-virtio-pmd-debug-log-output-reset-off.patch')
-rw-r--r--dpdk/dpdk-2.1.0_patches/0006-virtio-Cleanup-virtio-pmd-debug-log-output-reset-off.patch77
1 files changed, 77 insertions, 0 deletions
diff --git a/dpdk/dpdk-2.1.0_patches/0006-virtio-Cleanup-virtio-pmd-debug-log-output-reset-off.patch b/dpdk/dpdk-2.1.0_patches/0006-virtio-Cleanup-virtio-pmd-debug-log-output-reset-off.patch
new file mode 100644
index 00000000000..9306f112a2c
--- /dev/null
+++ b/dpdk/dpdk-2.1.0_patches/0006-virtio-Cleanup-virtio-pmd-debug-log-output-reset-off.patch
@@ -0,0 +1,77 @@
+From 21a9bf50270f71ebda5acb5fc233b8279cec56a7 Mon Sep 17 00:00:00 2001
+From: Shesha Sreenivasamurthy <shesha@cisco.com>
+Date: Wed, 2 Sep 2015 08:48:09 -0700
+Subject: [PATCH 6/9] virtio: Cleanup virtio pmd debug log output, reset
+ offload field
+
+---
+ drivers/net/virtio/virtio_ethdev.c | 10 +++++-----
+ drivers/net/virtio/virtio_rxtx.c | 4 +++-
+ 2 files changed, 8 insertions(+), 6 deletions(-)
+
+diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
+index 465d3cd..6a686fe 100644
+--- a/drivers/net/virtio/virtio_ethdev.c
++++ b/drivers/net/virtio/virtio_ethdev.c
+@@ -1521,24 +1521,24 @@ virtio_dev_link_update(struct rte_eth_dev *dev, __rte_unused int wait_to_complet
+ link.link_speed = SPEED_10G;
+
+ if (vtpci_with_feature(hw, VIRTIO_NET_F_STATUS)) {
+- PMD_INIT_LOG(DEBUG, "Get link status from hw");
+ vtpci_read_dev_config(hw,
+ offsetof(struct virtio_net_config, status),
+ &status, sizeof(status));
+ if ((status & VIRTIO_NET_S_LINK_UP) == 0) {
+ link.link_status = 0;
+- PMD_INIT_LOG(DEBUG, "Port %d is down",
+- dev->data->port_id);
+ } else {
+ link.link_status = 1;
+- PMD_INIT_LOG(DEBUG, "Port %d is up",
+- dev->data->port_id);
+ }
+ } else {
+ link.link_status = 1; /* Link up */
+ }
+ virtio_dev_atomic_write_link_status(dev, &link);
+
++ /* This message is far too noisy for normal use */
++ if (0)
++ PMD_INIT_LOG(DEBUG, "Port %d is %s\n", dev->data->port_id,
++ link.link_status ? "up" : "down");
++
+ return (old.link_status == link.link_status) ? -1 : 0;
+ }
+
+diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
+index c5b53bb..9f0b759 100644
+--- a/drivers/net/virtio/virtio_rxtx.c
++++ b/drivers/net/virtio/virtio_rxtx.c
+@@ -536,6 +536,7 @@ virtio_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
+ rxm->next = NULL;
+ rxm->pkt_len = (uint32_t)(len[i] - hdr_size);
+ rxm->data_len = (uint16_t)(len[i] - hdr_size);
++ rxm->ol_flags = 0;
+
+ if (hw->vlan_strip)
+ rte_vlan_strip(rxm);
+@@ -651,6 +652,7 @@ virtio_recv_mergeable_pkts(void *rx_queue,
+ rxm->next = NULL;
+ rxm->pkt_len = (uint32_t)(len[0] - hdr_size);
+ rxm->data_len = (uint16_t)(len[0] - hdr_size);
++ rxm->ol_flags = 0;
+
+ rxm->port = rxvq->port_id;
+ rx_pkts[nb_rx] = rxm;
+@@ -752,7 +754,7 @@ virtio_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)
+ if (unlikely(nb_pkts < 1))
+ return nb_pkts;
+
+- PMD_TX_LOG(DEBUG, "%d packets to xmit", nb_pkts);
++ PMD_TX_LOG(DEBUG, "%d packets to xmit\n", nb_pkts);
+ nb_used = VIRTQUEUE_NUSED(txvq);
+
+ virtio_rmb();
+--
+2.5.0
+
ref='#n301'>301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454