From: David Marchand <david.marchand@redhat.com>
To: Junxiao Shi <git@mail1.yoursunny.com>
Cc: dev <dev@dpdk.org>, "Yigit, Ferruh" <ferruh.yigit@intel.com>,
Ciara Loftus <ciara.loftus@intel.com>
Subject: Re: [PATCH v2] net/af_xdp: allow operation when multiprocess is disabled
Date: Thu, 17 Feb 2022 13:46:43 +0100 [thread overview]
Message-ID: <CAJFAV8y-jwVC6-sOyqXCouc=oe6fHUg5FZFhhhb3OybmKHbang@mail.gmail.com> (raw)
In-Reply-To: <2c422567d3640972@cs.arizona.edu>
On Thu, Feb 17, 2022 at 12:14 PM Junxiao Shi <git@mail1.yoursunny.com> wrote:
>
> If EAL multiprocess feature has been disabled via rte_mp_disable()
> function, AF_XDP driver may not be able to register its IPC callback.
> Previously this leads to probe failure.
> This commit adds a check for this condition so that AF_XDP can still be
> used even if multiprocess is disabled.
>
> Fixes: 9876cf8316b3 ("net/af_xdp: re-enable secondary process support")
>
> Signed-off-by: Junxiao Shi <git@mail1.yoursunny.com>
> ---
> drivers/net/af_xdp/rte_eth_af_xdp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
> index 6ac710c6bd..2163df7c5c 100644
> --- a/drivers/net/af_xdp/rte_eth_af_xdp.c
> +++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
> @@ -1995,7 +1995,7 @@ rte_pmd_af_xdp_probe(struct rte_vdev_device *dev)
> /* Register IPC callback which shares xsk fds from primary to secondary */
> if (!afxdp_dev_count) {
> ret = rte_mp_action_register(ETH_AF_XDP_MP_KEY, afxdp_mp_send_fds);
> - if (ret < 0) {
> + if (ret < 0 && rte_errno != ENOTSUP) {
> AF_XDP_LOG(ERR, "%s: Failed to register multi-process IPC callback: %s",
> name, strerror(rte_errno));
> return -1;
> --
> 2.17.1
>
I just encountered the same issue.
Patch lgtm.
--
David Marchand
next prev parent reply other threads:[~2022-02-17 12:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-16 15:59 [PATCH] " Junxiao Shi
2022-02-17 11:09 ` [PATCH v2] " Junxiao Shi
2022-02-17 12:46 ` David Marchand [this message]
2022-02-17 13:29 ` Loftus, Ciara
2022-02-17 17:29 ` 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='CAJFAV8y-jwVC6-sOyqXCouc=oe6fHUg5FZFhhhb3OybmKHbang@mail.gmail.com' \
--to=david.marchand@redhat.com \
--cc=ciara.loftus@intel.com \
--cc=dev@dpdk.org \
--cc=ferruh.yigit@intel.com \
--cc=git@mail1.yoursunny.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).