From: Mike Shang <mshang5@gmail.com>
To: users@dpdk.org
Subject: [dpdk-users] Getting pci id using port id with latest DPDK
Date: Thu, 23 Mar 2017 15:47:18 +0800 [thread overview]
Message-ID: <CAB6_+Dzx6so0fjw110o4r2DeuA9ZSzeiun+xSx9YuBmjdTgbBg@mail.gmail.com> (raw)
Hi,
I have legacy code that needs to get pci id using port id in order to make
different config for different pci device. In the past, we can do that with
a simple call to rte_eth_dev_info_get() and look into the pci_dev file in
rte_eth_dev_info structure. But with latest DPDK, rte_eth_dev_info_get() no
longer fills pci_dev after this commit (
http://dpdk.org/browse/dpdk/commit/lib/librte_ether/rte_ethdev.c?id=ae34410a8a8aff1b8382e16fcc89353648355be0
) Looks like the developers wanted to decouple pci device from a general
device.
Under such condition, how can I get the needed pci id from port id ? I scan
all function listed in rte_ethdev.h but didn't find such function. Maybe
there an indirect to do that? as a last resort, I can patch the dpdk source
code to make rte_eth_dev_info_get() fill pci_dev again but that may be the
last thing I would consider.....
next reply other threads:[~2017-03-23 7:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-23 7:47 Mike Shang [this message]
2017-03-23 9:16 ` Shreyansh Jain
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=CAB6_+Dzx6so0fjw110o4r2DeuA9ZSzeiun+xSx9YuBmjdTgbBg@mail.gmail.com \
--to=mshang5@gmail.com \
--cc=users@dpdk.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).