patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: Matan Azrad <matan@mellanox.com>
Cc: dev@dpdk.org, Ferruh Yigit <ferruh.yigit@intel.com>, stable@dpdk.org
Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH] net/vdev_netvsc: fix automatic probing
Date: Mon, 21 May 2018 09:52:14 -0700	[thread overview]
Message-ID: <20180521095214.2959d2c1@xeon-e3> (raw)
In-Reply-To: <1526919810-24303-1-git-send-email-matan@mellanox.com>

On Mon, 21 May 2018 16:23:30 +0000
Matan Azrad <matan@mellanox.com> wrote:

> The vdev_netvsc driver allows an automatic probe in Hyper-V VM systems
> unless it was already specified by the EAL command line.
> 
> The detection of a specified NetVSC device is wrongly done by comparing
> the vdev_netvsc driver name to all the vdev devices names, including
> the suffix device index. Thus, if the user specifies the vdev_netvsc
> device by adding an index to the device name, the comparison fails.
> Consequently, the vdev_netvsc driver may automatically probe NetVSC
> devices, despite the NetVSC device that was specified by the EAL command
> line.
> 
> Compare the vdev_netvsc driver name to the devices names without the
> index.
> 
> Fixes: 56252de779a6 ("net/vdev_netvsc: add automatic probing")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Matan Azrad <matan@mellanox.com>
> ---
>  drivers/net/vdev_netvsc/vdev_netvsc.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/vdev_netvsc/vdev_netvsc.c b/drivers/net/vdev_netvsc/vdev_netvsc.c
> index de2bd14..48717f2 100644
> --- a/drivers/net/vdev_netvsc/vdev_netvsc.c
> +++ b/drivers/net/vdev_netvsc/vdev_netvsc.c
> @@ -39,6 +39,7 @@
>  
>  #define VDEV_NETVSC_DRIVER net_vdev_netvsc
>  #define VDEV_NETVSC_DRIVER_NAME RTE_STR(VDEV_NETVSC_DRIVER)
> +#define VDEV_NETVSC_DRIVER_NAME_LEN 15

Looks correct, why did you not just use IFNAMSIZ which is commonly used
across much of the network code?

  reply	other threads:[~2018-05-21 16:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-21 16:23 [dpdk-stable] " Matan Azrad
2018-05-21 16:52 ` Stephen Hemminger [this message]
2018-05-21 17:25   ` [dpdk-stable] [dpdk-dev] " Matan Azrad
2018-05-22  9:57 ` [dpdk-stable] " 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=20180521095214.2959d2c1@xeon-e3 \
    --to=stephen@networkplumber.org \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=matan@mellanox.com \
    --cc=stable@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).