DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Wiles, Keith" <keith.wiles@intel.com>
To: Pascal Mazon <pascal.mazon@6wind.com>
Cc: "Yigit, Ferruh" <ferruh.yigit@intel.com>, "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH 1/6] net/tap: use correct tap name
Date: Wed, 1 Feb 2017 15:25:59 +0000	[thread overview]
Message-ID: <C74A55BC-4176-4CE7-9CF5-1343E371B567@intel.com> (raw)
In-Reply-To: <8a13261b-215c-e294-1f61-b57e5ea998eb@6wind.com>


> On Feb 1, 2017, at 2:11 AM, Pascal Mazon <pascal.mazon@6wind.com> wrote:
> 
> On 02/01/2017 12:29 AM, Wiles, Keith wrote:
>> 
>>> On Jan 31, 2017, at 10:39 AM, Pascal Mazon <pascal.mazon@6wind.com> wrote:
>>> 
>>> On 01/31/2017 05:06 PM, Wiles, Keith wrote:>
>>>> Looking at the changes to set the link up/down and the adding the two functions. I noticed in the stop/start routines I was set the link in DPDK and not adjusting the interface link. Should the stop/start routine also do the same thing?
>>>> 
>>> 
>>> Well, my patch is probably wrong.
>>> The best option would probably be to set dev->data->dev_link.link_status
>>> appropriately inside tap_link_set() only.
>>> 
>>> I'm not sure it's compulsory to actually set the link UP in tap_dev_start()
>>> (respectively DOWN in tap_dev_stop()).
>>> If it is, however, it would be best done using tap_link_set() in those
>>> functions.
>> 
>> I was setting the link up/down in both places in the old code. The gotta is link up/down came later (I guess) and applications only call start/stop. In the other drivers like ring the like they tend to set link in start/stop and in link up/down, which is what I patterned my driver on.
>> 
>> I looked around and the only applications calling link up/down was testpmd and ip_pipeline, but all of the apps call start/stop. Even the docs to not suggest that link up/down be used it appears start/stop must set the Link state and the developer can call link up/down APIs if needed for others reasons.
>> 
>> I assume the link up/down only effects the link state and the start/stop is creating/destroying resources.
>> 
>> My only solution I guess is to add the link up/down code to the start/stop API.
> 
> I'm not sure I understand your conclusion.
> If the apps usually call start/stop only, then definitely those functions should set the link state appropriately.
> To that effect, I think it best to just call tap_link_set() in tap_dev_start() (and similar for stopping).
> Apps with just start/stop functions would get the expected behavior, and the tap PMD would also support setting the link up/down independently, for testpmd and ip_pipeline for example.
> 
> Does that sound fine?

Yes, this was what I was trying to say and calling tap_link_set() in tap_dev_start() is the solution.

> 
> 
>> 
>>> 
>>> --
>>> Pascal Mazon
>>> www.6wind.com
>> 
>> Regards,
>> Keith
>> 
> 
> 
> -- 
> Pascal Mazon
> www.6wind.com

Regards,
Keith

  reply	other threads:[~2017-02-01 15:26 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-31  9:42 Pascal Mazon
2017-01-31  9:42 ` [dpdk-dev] [PATCH 2/6] net/tap: use correct channel for error logs Pascal Mazon
2017-01-31 13:07   ` Ferruh Yigit
2017-01-31 16:58     ` Stephen Hemminger
2017-01-31 17:04       ` Wiles, Keith
2017-01-31  9:42 ` [dpdk-dev] [PATCH 3/6] net/tap: don't set fd value overwritten just below Pascal Mazon
2017-01-31  9:42 ` [dpdk-dev] [PATCH 4/6] net/tap: keep kernel-assigned MAC address Pascal Mazon
2017-01-31 13:13   ` Ferruh Yigit
2017-01-31  9:42 ` [dpdk-dev] [PATCH 5/6] net/tap: display tap name after parsing Pascal Mazon
2017-01-31 13:16   ` Ferruh Yigit
2017-01-31  9:42 ` [dpdk-dev] [PATCH 6/6] net/tap: implement link up and down callbacks Pascal Mazon
2017-01-31 13:21   ` Ferruh Yigit
2017-01-31 14:31     ` Pascal Mazon
2017-01-31 13:06 ` [dpdk-dev] [PATCH 1/6] net/tap: use correct tap name Ferruh Yigit
2017-01-31 14:23   ` Pascal Mazon
2017-01-31 15:28     ` Ferruh Yigit
2017-01-31 15:30       ` Pascal Mazon
2017-01-31 15:38         ` Ferruh Yigit
2017-01-31 15:44           ` Wiles, Keith
2017-01-31 15:44             ` Pascal Mazon
2017-01-31 16:06               ` Wiles, Keith
2017-01-31 16:39                 ` Pascal Mazon
2017-01-31 23:29                   ` Wiles, Keith
2017-02-01  8:11                     ` Pascal Mazon
2017-02-01 15:25                       ` Wiles, Keith [this message]
2017-02-01 15:40                         ` Pascal Mazon
2017-02-01 15:55                           ` Wiles, Keith
2017-02-01 17:50                             ` Ferruh Yigit
2017-02-02  8:05                               ` Pascal Mazon
2017-02-02  8:25                                 ` Pascal Mazon
2017-02-02 10:23                                   ` Ferruh Yigit
2017-01-31 14:52 ` Wiles, Keith
2017-01-31 15:14   ` Ferruh Yigit
2017-01-31 15:19     ` Wiles, Keith
2017-02-02 13:46 ` Wiles, Keith
2017-02-02 16:17 ` [dpdk-dev] [PATCH v2 1/7] " Pascal Mazon
2017-02-02 16:17   ` [dpdk-dev] [PATCH v2 2/7] net/tap: use correct channel for error logs Pascal Mazon
2017-02-02 16:18   ` [dpdk-dev] [PATCH v2 3/7] net/tap: don't set fd value overwritten just below Pascal Mazon
2017-02-02 16:18   ` [dpdk-dev] [PATCH v2 4/7] net/tap: keep kernel-assigned MAC address Pascal Mazon
2017-02-02 16:18   ` [dpdk-dev] [PATCH v2 5/7] net/tap: display tap name after parsing Pascal Mazon
2017-02-02 16:18   ` [dpdk-dev] [PATCH v2 6/7] net/tap: implement link up and down callbacks Pascal Mazon
2017-02-02 16:18   ` [dpdk-dev] [PATCH v2 7/7] net/tap: support promiscuous and allmulti setting Pascal Mazon
2017-02-02 16:23   ` [dpdk-dev] [PATCH v2 1/7] net/tap: use correct tap name Wiles, Keith
2017-02-02 16:24     ` Wiles, Keith
2017-02-02 21:55       ` 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=C74A55BC-4176-4CE7-9CF5-1343E371B567@intel.com \
    --to=keith.wiles@intel.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=pascal.mazon@6wind.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).