netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Nikolay Aleksandrov <nikolay@redhat.com>
To: Veaceslav Falico <vfalico@redhat.com>
Cc: David Miller <davem@davemloft.net>,
	netdev@vger.kernel.org, fubar@us.ibm.com, jhs@mojatatu.com
Subject: Re: [net] net_sched: make dev_trans_start return vlan's real dev trans_start
Date: Sat, 03 Aug 2013 21:35:20 +0200	[thread overview]
Message-ID: <51FD5B78.6000208@redhat.com> (raw)
In-Reply-To: <20130803190918.GA11976@redhat.com>

On 08/03/2013 09:09 PM, Veaceslav Falico wrote:
> On Sat, Aug 03, 2013 at 11:52:28AM -0700, David Miller wrote:
>> From: Veaceslav Falico <vfalico@redhat.com>
>> Date: Sat, 3 Aug 2013 19:07:33 +0200
>>
>>> On Sat, Aug 03, 2013 at 05:07:51PM +0200, nikolay@redhat.com wrote:
>>> ...snip...
>>>> +    while (is_vlan_dev(dev))
>>>> +        dev = vlan_dev_real_dev(dev);
>>>
>>> While at it - I've checked a few users (mainly network drivers) of
>>> vlan_dev_real_dev(dev) and they all rely on that the return device
>>> would be the *real* device, but not another vlan.
>>
>> Did you find any cases that want the device under the VLAN,
>> whether it is a non-vlan device or not?
> 
> Not really. All of the cases seem to explicitly call it to get a non-vlan
> device, and not the purely 'underlying' one.
> 
> Another point is that they won't work properly with QinQ... cause the
> majority of callers are searching for their own device. Or bonding, as in
> netxen that Nik mentioned. And they will find yet another vlan device.
> 
> So either QinQ isn't really that used or I'm missing something...
> 
>>
>>> So maybe we should move this while loop to vlan_dev_real_dev()
>>> instead?
>>
>> Perhaps.  As per above, we may also need the one-level demux
>> helper too, something like "vlan_dev_slave(dev)".
> 
> I haven't found any usage for it, tbh. Only the vlan code itself might
> benefit from it, but it already uses the vlan_dev_priv(dev)->real_dev, and
> not the vlan_dev_real_dev(), which is used by drivers.
I agree with this. I also can't find users of the one-level variant, so I
think it'd be safe to go ahead and do it.
Just one question in case that we all agree -
Dave should I queue the patches (vlan change & net_sched's dev_trans_start)
for net-next or net would be fine ?

Thanks,
 Nik

  reply	other threads:[~2013-08-03 19:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-03 15:07 [PATCH net] net_sched: make dev_trans_start return vlan's real dev trans_start Nikolay Aleksandrov
2013-08-03 17:07 ` [net] " Veaceslav Falico
2013-08-03 18:13   ` Nikolay Aleksandrov
2013-08-03 18:19     ` Nikolay Aleksandrov
2013-08-03 18:25       ` Veaceslav Falico
2013-08-03 18:52   ` David Miller
2013-08-03 19:09     ` Veaceslav Falico
2013-08-03 19:35       ` Nikolay Aleksandrov [this message]
2013-08-03 19:37         ` David Miller
2013-08-03 19:37       ` David Miller

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=51FD5B78.6000208@redhat.com \
    --to=nikolay@redhat.com \
    --cc=davem@davemloft.net \
    --cc=fubar@us.ibm.com \
    --cc=jhs@mojatatu.com \
    --cc=netdev@vger.kernel.org \
    --cc=vfalico@redhat.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).