Thread (3 messages) 3 messages, 2 authors, 2008-03-04

Re: capturing vlan on 2.6.18

From: Pekka Pietikainen <hidden>
Date: 2008-03-04 11:18:51

On Thu, Feb 28, 2008 at 12:26:08PM +0100, Pavel Krauz wrote:
quoted hunk ↗ jump to hunk
quoted
quoted
Is this a kernel bug or am I supposed to set something?
It's an unfortunate side effect of hardware VLAN acceleration. It
can't be turned off (apart from patching the driver to not advertise
VLAN acceleration support).
I think that enabling VLAN tags shall be at least kernel run-time or boot time
 configurable option.

For a test I have tried to enable VLAN tags in the Broadcom NX2 network driver (drivers/net/bnx2.c)
and I got the VLAN back. Can you tell me if this is the correct way:
--- bnx2.c.bak  2008-02-28 11:47:29.000000000 +0100
+++ bnx2.c      2008-02-28 11:47:43.000000000 +0100
@@ -2039,6 +2039,7 @@
 #endif
        if (dev->flags & IFF_PROMISC) {
                /* Promiscuous mode. */
+               rx_mode |= BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG;
                rx_mode |= BNX2_EMAC_RX_MODE_PROMISCUOUS;
                sort_mode |= BNX2_RPM_SORT_USER0_PROM_EN;
        }
Oh, the no VLAN tags with bnx2 is a slightly different matter,
I've used the patch

#ifdef BCM_VLAN
        if (!bp->vlgrp && !(bp->flags & ASF_ENABLE_FLAG))
                rx_mode |= BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG;
#else

->
        if (!bp->vlgrp) // && !(bp->flags & ASF_ENABLE_FLAG))
                rx_mode |= BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG;

Apparently there's a DOS tool that can be used to disable the ASF bit
(It's some enterprise management thing that I haven't ever figured out what
it's even useful for) permanently, 
http://www.broadcom.com/support/ethernet_nic/netxtremeii.php

Since I need lots of ports on my monitoring boxes anyway, I just use
external dual-port e1000's for monitoring and use the on-board bnx2 for
managment. Much easier :-)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help