From: Patrick McHardy <kaber@trash.net>
To: Stephen Hemminger <shemminger@linux-foundation.org>
Cc: Linux Netdev List <netdev@vger.kernel.org>,
Ben Greear <greearb@candelatech.com>
Subject: Re: [PATCH]: sky2: Fix VLAN unregistration
Date: Fri, 01 Jun 2007 17:16:24 +0200 [thread overview]
Message-ID: <46603848.5000604@trash.net> (raw)
In-Reply-To: <20070531112117.584141d6@freepuppy>
Stephen Hemminger wrote:
> On Thu, 31 May 2007 19:37:07 +0200
> Patrick McHardy <kaber@trash.net> wrote:
>
>
>>Stephen Hemminger wrote:
>>
>>>On Sun, 27 May 2007 20:44:04 +0200
>>>Patrick McHardy <kaber@trash.net> wrote:
>>>
>>>
>>>
>>>>Fix sky2 disabling VLAN completely when the first vid is unregistered.
>>>>
>>>>For some reason the VLAN code insists on the driver providing a
>>>>vlan_rx_kill_vid function even if only NETIF_F_HW_VLAN_RX and not
>>>>NETIF_F_HW_VLAN_FILTER is set, so this patch keeps an empty
>>>>function. This seems to be a bug though, vlan_rx_add_vid is only
>>>>required with NETIF_F_HW_VLAN_FILTER. Ben?
>>>>
>>>
>>>
>>>Reading other drivers, it looks like a better patch would be to
>>>handle mode change in both set and kill.
>>
>>
>>The VLAN code tracks registered VIDs and will always call
>>vlan_rx_register(NULL) when the last VID is unregistered,
>>so this is not necessary.
>>
>
>
> Then should others be fixed...
> tg3, bnx2, r8169, gianfar, s2io, 8139cp, acenic, ...
tg3 and r8169 both look fine, they only unregister a single VID
within kill_vid and rely on VLAN to call rx_register(NULL) when
the group is unregistered (haven't looked at the others).
As I wrote in my previous mails, they do have a part that looks
unnecessary
tg3_full_lock(tp, 0);
vlan_group_set_device(tp->vlgrp, vid, NULL);
tg3_full_unlock(tp);
since the vid is also removed by the VLAN code itself and locking
doesn't seem to be necessary because the VLAN hwaccel rx helper
deals with removal races itself.
next prev parent reply other threads:[~2007-06-01 15:17 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-27 18:44 [SKY2]: Fix VLAN unregistration Patrick McHardy
2007-05-28 21:42 ` Ben Greear
2007-05-29 10:57 ` Patrick McHardy
2007-05-29 17:16 ` Stephen Hemminger
2007-05-31 17:19 ` [PATCH]: sky2: " Stephen Hemminger
2007-05-31 17:37 ` Patrick McHardy
2007-05-31 18:21 ` Stephen Hemminger
2007-06-01 15:16 ` Patrick McHardy [this message]
2007-06-01 16:16 ` 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=46603848.5000604@trash.net \
--to=kaber@trash.net \
--cc=greearb@candelatech.com \
--cc=netdev@vger.kernel.org \
--cc=shemminger@linux-foundation.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).