lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 21 Sep 2007 15:02:38 -0700
From:	"Chris Leech" <chris.leech@...il.com>
To:	hadi@...erus.ca
Cc:	"Kok, Auke" <auke-jan.h.kok@...el.com>,
	"Ben Greear" <greearb@...delatech.com>,
	"Emil Micek" <emil.micek@...jasek.cz>,
	"netdev mailing list" <netdev@...r.kernel.org>,
	Jesse <jesse.brandeburg@...el.com>
Subject: Re: change the way e1000 is handling short VLAN frames

On 9/21/07, jamal <hadi@...erus.ca> wrote:
> On Fri, 2007-21-09 at 14:34 -0700, Kok, Auke wrote:
>
> > I never saw any bugreports about e1000 not being able to accept vlan packets
> > because of this, so I'm quite certain it works OK, feel free to find me a case
> > where this isn't so :)
>
> If you tell me it can be done on the rx, i will take your word for it;->
> Emil can certainly verify it.
> The tx you certainly have issues - Look at one of the suggestions from
> Chris, i think it is resolvable.

I'd say that devices that can't receive 64 bytes VLAN tagged frames
have an issue, but for the sake of interoperability and solving Emil's
problem I'm willing to discuss how a change to e1000 would work  ;-)

The simplest option is to add software small frame padding all the
time.  It won't catch software tagged frames if they were generated
somehow, but should fix the hardware tagged ones to be 68 bytes on the
wire.  If you were worried about software tagged frames then replacing
ETH_ZLEN with VLAN_ETH_ZLEN would pad all frames, VLAN or not, to 68
bytes.

Emil, this patch will probably do what you want.

diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
index 4a22595..34e3d18 100644
--- a/drivers/net/e1000/e1000_main.c
+++ b/drivers/net/e1000/e1000_main.c
@@ -3284,6 +3284,9 @@ e1000_xmit_frame(struct sk_buff *skb, struct
net_device *netdev)
                return NETDEV_TX_OK;
        }

+       if (skb_padto(skb, ETH_ZLEN))
+               return NETDEV_TX_OK;
+
        /* 82571 and newer doesn't need the workaround that limited descriptor
         * length to 4kB */
        if (adapter->hw.mac_type >= e1000_82571)
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ