From: Ivan Vecera <ivecera@redhat.com>
To: netdev@vger.kernel.org
Cc: Rasesh Mody <rmody@brocade.com>
Subject: [PATCH net] bna: don't disable VLAN tag stripping in promisc mode
Date: Thu, 27 Feb 2014 19:17:22 +0100 [thread overview]
Message-ID: <1393525042-7791-1-git-send-email-ivecera@redhat.com> (raw)
The recent commit "fe1624c bna: RX Filter Enhancements" disables
VLAN tag stripping if the NIC is in promiscuous mode. Received VLAN tagged
packets are recognized by the driver via BNA_CQ_EF_VLAN flag and for such
packets the driver calls __vlan_hwaccel_put_tag(). The problem is the HW
marks the tagged packets with this flags also when the stripping is
disabled and thus __vlan_hwaccel_put_tag() should not be called for them.
A solution can be to call __vlan_hwaccel_put_tag() only when stripping is
enabled or to leave VLAN stripping engine enabled. The 2nd restores the
previous behavior and is IMHO better.
Cc: Rasesh Mody <rmody@brocade.com>
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
---
drivers/net/ethernet/brocade/bna/bnad.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/net/ethernet/brocade/bna/bnad.c b/drivers/net/ethernet/brocade/bna/bnad.c
index cf64f3d..137e91a 100644
--- a/drivers/net/ethernet/brocade/bna/bnad.c
+++ b/drivers/net/ethernet/brocade/bna/bnad.c
@@ -3245,11 +3245,6 @@ bnad_set_rx_mode(struct net_device *netdev)
BNA_RXMODE_ALLMULTI;
bna_rx_mode_set(bnad->rx_info[0].rx, new_mode, mode_mask, NULL);
- if (bnad->cfg_flags & BNAD_CF_PROMISC)
- bna_rx_vlan_strip_disable(bnad->rx_info[0].rx);
- else
- bna_rx_vlan_strip_enable(bnad->rx_info[0].rx);
-
spin_unlock_irqrestore(&bnad->bna_lock, flags);
}
--
1.8.3.2
next reply other threads:[~2014-02-27 18:17 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-27 18:17 Ivan Vecera [this message]
2014-02-27 19:59 ` [PATCH net] bna: don't disable VLAN tag stripping in promisc mode Jiri Pirko
2014-02-27 22:24 ` David Miller
2014-02-28 6:31 ` Jiri Pirko
2014-02-28 9:09 ` Ivan Vecera
2014-02-28 17:55 ` 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=1393525042-7791-1-git-send-email-ivecera@redhat.com \
--to=ivecera@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=rmody@brocade.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).