DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ferruh Yigit <ferruh.yigit@amd.com>
To: madhuker.mythri@oracle.com, grive@u256.net
Cc: dev@dpdk.org
Subject: Re: [PATCH] net/failsafe: Fix crash due to in-valid sub-device port id
Date: Wed, 7 Dec 2022 17:21:42 +0000	[thread overview]
Message-ID: <8971e9a0-e9d0-4da8-1cc3-a1ffbf6ad8f0@amd.com> (raw)
In-Reply-To: <20221116121121.1969-1-madhuker.mythri@oracle.com>

On 11/16/2022 12:11 PM, madhuker.mythri@oracle.com wrote:
> From: Madhuker Mythri <madhuker.mythri@oracle.com>
> 
> Crash occurring while the DPDK secondary processes trying to probe the
> tap-device, where tap-device is a sub-device of Fail-safe device.
> Some-times we get in-valid sub-devices(with the in-valid port-id's),
> due to which the IPC communication does not get response and causes the
> communication failures b/w primary/secondary process.
> So, need to validate the sub-device(tap) while secondary process probe in
> the Fail-safe PMD, to avoid such issues.
> 
> Bugzilla Id: 1116
> 
> Signed-off-by: Madhuker Mythri <madhuker.mythri@oracle.com>
> ---
>  drivers/net/failsafe/failsafe.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/net/failsafe/failsafe.c b/drivers/net/failsafe/failsafe.c
> index 32811403b4..51d4440ac7 100644
> --- a/drivers/net/failsafe/failsafe.c
> +++ b/drivers/net/failsafe/failsafe.c
> @@ -361,6 +361,9 @@ rte_pmd_failsafe_probe(struct rte_vdev_device *vdev)
>  			if (sdev->devargs.name[0] == '\0')
>  				continue;
>  
> +			if (!rte_eth_dev_is_valid_port(PORT_ID(sdev)))
> +				continue;
> +


This is in the 'FOREACH_SUBDEV()' block, why an invalid subdevice
provided by the macro?

Instead of invalid port check, should we fix the macro?

Overall I am not clear why this defect occurs, bugzilla report also
don't have much detail.
Can you please provide more details why this defect happens?


  reply	other threads:[~2022-12-07 17:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-16 12:11 madhuker.mythri
2022-12-07 17:21 ` Ferruh Yigit [this message]
2023-10-17 16:49   ` Stephen Hemminger
  -- strict thread matches above, loose matches on Subject: below --
2022-11-16  9:52 madhuker.mythri
2022-11-16 17:51 ` Stephen Hemminger

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=8971e9a0-e9d0-4da8-1cc3-a1ffbf6ad8f0@amd.com \
    --to=ferruh.yigit@amd.com \
    --cc=dev@dpdk.org \
    --cc=grive@u256.net \
    --cc=madhuker.mythri@oracle.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).