DPDK patches and discussions
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: dev@dpdk.org
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	Martin Spinler <spinler@cesnet.cz>
Subject: [PATCH 1/3] net/nfb: remove unused device args
Date: Thu,  7 Dec 2023 10:56:29 -0800	[thread overview]
Message-ID: <20231207185720.19913-2-stephen@networkplumber.org> (raw)
In-Reply-To: <20231207185720.19913-1-stephen@networkplumber.org>

The driver has no entries in VALID_KEYS array so there are
no device args. And after parsing it just frees the result.
Looks like it was copy/pasted from some other driver.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/nfb/nfb.h        |  2 --
 drivers/net/nfb/nfb_ethdev.c | 16 ----------------
 2 files changed, 18 deletions(-)

diff --git a/drivers/net/nfb/nfb.h b/drivers/net/nfb/nfb.h
index 7dc5bd29e44c..21cd8f78f641 100644
--- a/drivers/net/nfb/nfb.h
+++ b/drivers/net/nfb/nfb.h
@@ -36,8 +36,6 @@
 
 #define RTE_NFB_DRIVER_NAME net_nfb
 
-/* Device arguments */
-static const char * const VALID_KEYS[] = {NULL};
 
 struct pmd_internals {
 	uint16_t         max_rxmac;
diff --git a/drivers/net/nfb/nfb_ethdev.c b/drivers/net/nfb/nfb_ethdev.c
index defd118bd0ee..4c4e2e3273e6 100644
--- a/drivers/net/nfb/nfb_ethdev.c
+++ b/drivers/net/nfb/nfb_ethdev.c
@@ -518,7 +518,6 @@ nfb_eth_dev_init(struct rte_eth_dev *dev)
 	struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(dev);
 	struct rte_pci_addr *pci_addr = &pci_dev->addr;
 	struct rte_ether_addr eth_addr_init;
-	struct rte_kvargs *kvlist;
 
 	RTE_LOG(INFO, PMD, "Initializing NFB device (" PCI_PRI_FMT ")\n",
 		pci_addr->domain, pci_addr->bus, pci_addr->devid,
@@ -529,21 +528,6 @@ nfb_eth_dev_init(struct rte_eth_dev *dev)
 		pci_addr->domain, pci_addr->bus, pci_addr->devid,
 		pci_addr->function);
 
-	/* Check validity of device args */
-	if (dev->device->devargs != NULL &&
-			dev->device->devargs->args != NULL &&
-			strlen(dev->device->devargs->args) > 0) {
-		kvlist = rte_kvargs_parse(dev->device->devargs->args,
-						VALID_KEYS);
-		if (kvlist == NULL) {
-			RTE_LOG(ERR, PMD, "Failed to parse device arguments %s",
-				dev->device->devargs->args);
-			rte_kvargs_free(kvlist);
-			return -EINVAL;
-		}
-		rte_kvargs_free(kvlist);
-	}
-
 	/*
 	 * Get number of available DMA RX and TX queues, which is maximum
 	 * number of queues that can be created and store it in private device
-- 
2.42.0


  reply	other threads:[~2023-12-07 18:57 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-06 17:51 [RFT] net/nfb: use dynamic logtype Stephen Hemminger
2023-12-07 10:37 ` Martin Spinler
2023-12-07 17:32   ` Stephen Hemminger
2023-12-07 18:56 ` [PATCH 0/3] net/nfb: driver cleanups Stephen Hemminger
2023-12-07 18:56   ` Stephen Hemminger [this message]
2023-12-07 18:56   ` [PATCH 2/3] net/nfb: make device path local to init function Stephen Hemminger
2023-12-07 18:56   ` [PATCH 3/3] net/nfb: use dynamic logtype Stephen Hemminger
2023-12-12  8:49     ` Martin Spinler
2024-01-12 12:16   ` [PATCH 0/3] net/nfb: driver cleanups Ferruh Yigit
2024-01-12 13:50     ` Martin Spinler
2024-02-08  1:02       ` Ferruh Yigit
2024-02-08 12:01   ` Ferruh Yigit

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=20231207185720.19913-2-stephen@networkplumber.org \
    --to=stephen@networkplumber.org \
    --cc=dev@dpdk.org \
    --cc=spinler@cesnet.cz \
    /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).