DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ferruh Yigit <ferruh.yigit@intel.com>
To: dev@dpdk.org
Cc: Bruce Richardson <bruce.richardson@intel.com>,
	Neil Horman <nhorman@tuxdriver.com>
Subject: [dpdk-dev] [PATCH] net/ring: fix ring eth dev creation via devargs
Date: Wed, 31 Aug 2016 17:51:11 +0100	[thread overview]
Message-ID: <1472662271-21880-1-git-send-email-ferruh.yigit@intel.com> (raw)

Using nodeaction devarg lets creating multiple ring eth devices:
"eth_ring0,nodeaction=R0:0:CREATE,nodeaction=R1:0:CREATE"

Trying to create all devices with same name fails. Since first part of
the nodeaction devarg is name (in above sample R0,R1), this name field
can be used as eth dev name.

Fixes: 61934c0956d4 ("ring: convert to use of PMD_REGISTER_DRIVER and fix linking")

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/ring/rte_eth_ring.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ring/rte_eth_ring.c b/drivers/net/ring/rte_eth_ring.c
index a7048c7..5551e18 100644
--- a/drivers/net/ring/rte_eth_ring.c
+++ b/drivers/net/ring/rte_eth_ring.c
@@ -557,7 +557,7 @@ rte_pmd_ring_devinit(const char *name, const char *params)
 				goto out_free;
 
 			for (info->count = 0; info->count < info->total; info->count++) {
-				ret = eth_dev_ring_create(name,
+				ret = eth_dev_ring_create(info->list[info->count].name,
 							  info->list[info->count].node,
 							  info->list[info->count].action);
 				if ((ret == -1) &&
-- 
2.7.4

             reply	other threads:[~2016-08-31 16:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-31 16:51 Ferruh Yigit [this message]
2016-10-13 10:21 ` Bruce Richardson
2016-10-13 13:42   ` Bruce Richardson

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=1472662271-21880-1-git-send-email-ferruh.yigit@intel.com \
    --to=ferruh.yigit@intel.com \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=nhorman@tuxdriver.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).