DPDK patches and discussions
 help / color / mirror / Atom feed
From: David Marchand <david.marchand@redhat.com>
To: dev@dpdk.org
Cc: stable@dpdk.org, Neil Horman <nhorman@tuxdriver.com>,
	Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>,
	Stephen Hemminger <stephen@networkplumber.org>,
	Bruce Richardson <bruce.richardson@intel.com>
Subject: [dpdk-dev] [PATCH] usertools/pmdinfo: fix plugin auto scan
Date: Tue, 19 Oct 2021 14:52:30 +0200	[thread overview]
Message-ID: <20211019125230.27480-1-david.marchand@redhat.com> (raw)

Migration to argparse was incomplete.

$ dpdk-pmdinfo.py -p $(which dpdk-testpmd)
Traceback (most recent call last):
  File "/usr/bin/dpdk-pmdinfo.py", line 626, in <module>
    main()
  File "/usr/bin/dpdk-pmdinfo.py", line 596, in main
    exit(scan_for_autoload_pmds(args[0]))
TypeError: 'Namespace' object does not support indexing

Fixes: 81255f27c65c ("usertools: replace optparse with argparse")
Cc: stable@dpdk.org

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 usertools/dpdk-pmdinfo.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/usertools/dpdk-pmdinfo.py b/usertools/dpdk-pmdinfo.py
index 3381aa616c..40ef5cec6c 100755
--- a/usertools/dpdk-pmdinfo.py
+++ b/usertools/dpdk-pmdinfo.py
@@ -593,7 +593,7 @@ def main(stream=None):
             exit(1)
 
     if args.pdir:
-        exit(scan_for_autoload_pmds(args[0]))
+        exit(scan_for_autoload_pmds(args.elf_file))
 
     ldlibpath = os.environ.get('LD_LIBRARY_PATH')
     if ldlibpath is None:
-- 
2.23.0


             reply	other threads:[~2021-10-19 12:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-19 12:52 David Marchand [this message]
2021-10-20 19:31 ` Robin Jarry
2021-10-25 15:10   ` Thomas Monjalon

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=20211019125230.27480-1-david.marchand@redhat.com \
    --to=david.marchand@redhat.com \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=dmitry.kozliuk@gmail.com \
    --cc=nhorman@tuxdriver.com \
    --cc=stable@dpdk.org \
    --cc=stephen@networkplumber.org \
    /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).