DPDK patches and discussions
 help / color / mirror / Atom feed
From: Yongseok Koh <yskoh@mellanox.com>
To: adrien.mazarguil@6wind.com, nelio.laranjeiro@6wind.com
Cc: dev@dpdk.org, shahafs@mellanox.com, Yongseok Koh <yskoh@mellanox.com>
Subject: [dpdk-dev] [PATCH v2 3/5] net/mlx5: add warning message for Multi-Packet RQ
Date: Tue, 26 Jun 2018 05:39:23 -0700	[thread overview]
Message-ID: <20180626123925.37439-4-yskoh@mellanox.com> (raw)
In-Reply-To: <20180626123925.37439-1-yskoh@mellanox.com>

If Multi-Packet RQ is enabled but not supported by device or
kernel/library, print out a warning message.

Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
---
 drivers/net/mlx5/mlx5.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c
index 49b400503..f0e6ed726 100644
--- a/drivers/net/mlx5/mlx5.c
+++ b/drivers/net/mlx5/mlx5.c
@@ -1024,8 +1024,7 @@ mlx5_pci_probe(struct rte_pci_driver *pci_drv __rte_unused,
 			DRV_LOG(WARNING, "Rx CQE compression isn't supported");
 			config.cqe_comp = 0;
 		}
-		config.mprq.enabled = config.mprq.enabled && mprq;
-		if (config.mprq.enabled) {
+		if (config.mprq.enabled && mprq) {
 			if (config.mprq.stride_num_n > mprq_max_stride_num_n ||
 			    config.mprq.stride_num_n < mprq_min_stride_num_n) {
 				config.mprq.stride_num_n =
@@ -1039,6 +1038,9 @@ mlx5_pci_probe(struct rte_pci_driver *pci_drv __rte_unused,
 			}
 			config.mprq.min_stride_size_n = mprq_min_stride_size_n;
 			config.mprq.max_stride_size_n = mprq_max_stride_size_n;
+		} else if (config.mprq.enabled && !mprq) {
+			DRV_LOG(WARNING, "Multi-Packet RQ isn't supported");
+			config.mprq.enabled = 0;
 		}
 		eth_dev = rte_eth_dev_allocate(name);
 		if (eth_dev == NULL) {
-- 
2.11.0

  parent reply	other threads:[~2018-06-26 12:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-26 12:39 [dpdk-dev] [PATCH v2 0/5] net/mlx5: support new completion field " Yongseok Koh
2018-06-26 12:39 ` [dpdk-dev] [PATCH v2 1/5] net/mlx5: change return value of Rx completion poll Yongseok Koh
2018-06-26 12:39 ` [dpdk-dev] [PATCH v2 2/5] net/mlx5: add new fields in Rx completion entry Yongseok Koh
2018-06-26 12:39 ` Yongseok Koh [this message]
2018-06-26 12:39 ` [dpdk-dev] [PATCH v2 4/5] net/mlx5: use stride index " Yongseok Koh
2018-06-26 12:39 ` [dpdk-dev] [PATCH v2 5/5] net/mlx5: increase number of strides Yongseok Koh
2018-06-27 10:46 ` [dpdk-dev] [PATCH v2 0/5] net/mlx5: support new completion field for Multi-Packet RQ Shahaf Shuler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180626123925.37439-4-yskoh@mellanox.com \
    --to=yskoh@mellanox.com \
    --cc=adrien.mazarguil@6wind.com \
    --cc=dev@dpdk.org \
    --cc=nelio.laranjeiro@6wind.com \
    --cc=shahafs@mellanox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).