<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/net/8021q, branch linux-2.6.36.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.36.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.36.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2010-12-09T21:33:29Z</updated>
<entry>
<title>vlan: Avoid hwaccel vlan packets when vid not used.</title>
<updated>2010-12-09T21:33:29Z</updated>
<author>
<name>Jesse Gross</name>
</author>
<published>2010-11-08T21:23:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1b7cd15c8c89f5c26dc525d985e45c9bd9265fe2'/>
<id>urn:sha1:1b7cd15c8c89f5c26dc525d985e45c9bd9265fe2</id>
<content type='text'>
[This patch applies only to 2.6.36 stable.  The problem was introduced
in that release and is already fixed by larger changes to the vlan
code in 2.6.37.]

Normally hardware accelerated vlan packets are quickly dropped if
there is no corresponding vlan device configured.  The one exception
is promiscuous mode, where we allow all of these packets through so
they can be picked up by tcpdump.  However, this behavior causes a
crash if we actually try to receive these packets.  This fixes that
crash by ignoring packets with vids not corresponding to a configured
device in the vlan hwaccel routines and then dropping them before they
get to consumers in the network stack.


Reported-by: Ben Greear &lt;greearb@candelatech.com&gt;
Tested-by: Nikola Ciprich &lt;extmaillist@linuxbox.cz&gt;
Signed-off-by: Jesse Gross &lt;jesse@nicira.com&gt;
Acked-by: David Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>vlan: dont drop packets from unknown vlans in promiscuous mode</title>
<updated>2010-10-01T01:04:21Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2010-09-30T02:16:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=173e79fb70a98b5b223f8dc09c22990d777bdd78'/>
<id>urn:sha1:173e79fb70a98b5b223f8dc09c22990d777bdd78</id>
<content type='text'>
Roger Luethi noticed packets for unknown VLANs getting silently dropped
even in promiscuous mode.

Check for promiscuous mode in __vlan_hwaccel_rx() and vlan_gro_common()
before drops.

As suggested by Patrick, mark such packets to have skb-&gt;pkt_type set to
PACKET_OTHERHOST to make sure they are dropped by IP stack.

Reported-by: Roger Luethi &lt;rl@hellgate.ch&gt;
Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
CC: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>vlan: Match underlying dev carrier on vlan add</title>
<updated>2010-08-19T07:26:46Z</updated>
<author>
<name>Phil Oester</name>
</author>
<published>2010-08-17T18:45:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0ac820eebe9008094040955d294ef7b33b418413'/>
<id>urn:sha1:0ac820eebe9008094040955d294ef7b33b418413</id>
<content type='text'>
When adding a new vlan, if the underlying interface has no carrier,
then the newly added vlan interface should also have no carrier.
At present, this is not true - the newly added vlan is added with
carrier up.  Fix by checking state of real device.

Signed-off-by: Phil Oester &lt;kernel@linuxace.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>vlan_dev: VLAN 0 should be treated as "no vlan tag" (802.1p packet)</title>
<updated>2010-07-18T22:38:44Z</updated>
<author>
<name>Pedro Garcia</name>
</author>
<published>2010-07-18T22:38:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ad1afb00393915a51c21b1ae8704562bf036855f'/>
<id>urn:sha1:ad1afb00393915a51c21b1ae8704562bf036855f</id>
<content type='text'>
- Without the 8021q module loaded in the kernel, all 802.1p packets 
(VLAN 0 but QoS tagging) are silently discarded (as expected, as 
the protocol is not loaded).
 
- Without this patch in 8021q module, these packets are forwarded to 
the module, but they are discarded also if VLAN 0 is not configured,
which should not be the default behaviour, as VLAN 0 is not really
a VLANed packet but a 802.1p packet. Defining VLAN 0 makes it almost
impossible to communicate with mixed 802.1p and non 802.1p devices on
the same network due to arp table issues.

- Changed logic to skip vlan specific code in vlan_skb_recv if VLAN 
is 0 and we have not defined a VLAN with ID 0, but we accept the 
packet with the encapsulated proto and pass it later to netif_rx.

- In the vlan device event handler, added some logic to add VLAN 0 
to HW filter in devices that support it (this prevented any traffic
in VLAN 0 to reach the stack in e1000e with HW filter under 2.6.35,
and probably also with other HW filtered cards, so we fix it here).

- In the vlan unregister logic, prevent the elimination of VLAN 0 
in devices with HW filter.

- The default behaviour is to ignore the VLAN 0 tagging and accept
the packet as if it was not tagged, but we can still define a 
VLAN 0 if desired (so it is backwards compatible).

Signed-off-by: Pedro Garcia &lt;pedro.netdev@dondevamos.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: Get rid of rtnl_link_stats64 / net_device_stats union</title>
<updated>2010-07-10T00:41:56Z</updated>
<author>
<name>Ben Hutchings</name>
</author>
<published>2010-07-09T09:11:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3cfde79c6c7c8002375c4a8e5be7f602fbb9675d'/>
<id>urn:sha1:3cfde79c6c7c8002375c4a8e5be7f602fbb9675d</id>
<content type='text'>
In commit be1f3c2c027cc5ad735df6a45a542ed1db7ec48b "net: Enable 64-bit
net device statistics on 32-bit architectures" I redefined struct
net_device_stats so that it could be used in a union with struct
rtnl_link_stats64, avoiding the need for explicit copying or
conversion between the two.  However, this is unsafe because there is
no locking required and no lock consistently held around calls to
dev_get_stats() and use of the statistics structure it returns.

In commit 28172739f0a276eb8d6ca917b3974c2edb036da3 "net: fix 64 bit
counters on 32 bit arches" Eric Dumazet dealt with that problem by
requiring callers of dev_get_stats() to provide storage for the
result.  This means that the net_device::stats64 field and the padding
in struct net_device_stats are now redundant, so remove them.

Update the comment on net_device_ops::ndo_get_stats64 to reflect its
new usage.

Change dev_txq_stats_fold() to use struct rtnl_link_stats64, since
that is what all its callers are really using and it is no longer
going to be compatible with struct net_device_stats.

Eric Dumazet suggested the separate function for the structure
conversion.

Signed-off-by: Ben Hutchings &lt;bhutchings@solarflare.com&gt;
Acked-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>vlan: allow TSO setting on vlan interfaces</title>
<updated>2010-07-09T06:12:21Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2010-07-09T06:12:21Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a204b48ed4dc31acf61090e530430ce3272b6aab'/>
<id>urn:sha1:a204b48ed4dc31acf61090e530430ce3272b6aab</id>
<content type='text'>
When we need to shape traffic using low speeds, we need to
disable tso on network interface :

ethtool -K eth0.2240 tso off

It seems vlan interfaces miss the set_tso() ethtool method.

Before enabling TSO, we must check real device supports
TSO for VLAN-tagged packets and enables TSO.

Note that a TSO change on real device propagates TSO setting
on all vlans, even if admin selected a different TSO setting.

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: Ben Hutchings &lt;bhutchings@solarflare.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: fix 64 bit counters on 32 bit arches</title>
<updated>2010-07-07T21:58:56Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2010-07-07T21:58:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=28172739f0a276eb8d6ca917b3974c2edb036da3'/>
<id>urn:sha1:28172739f0a276eb8d6ca917b3974c2edb036da3</id>
<content type='text'>
There is a small possibility that a reader gets incorrect values on 32
bit arches. SNMP applications could catch incorrect counters when a
32bit high part is changed by another stats consumer/provider.

One way to solve this is to add a rtnl_link_stats64 param to all
ndo_get_stats64() methods, and also add such a parameter to
dev_get_stats().

Rule is that we are not allowed to use dev-&gt;stats64 as a temporary
storage for 64bit stats, but a caller provided area (usually on stack)

Old drivers (only providing get_stats() method) need no changes.

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>vlan: 64 bit rx counters</title>
<updated>2010-06-29T06:24:31Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2010-06-24T00:55:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9618e2ffd78aaa43a5815e1dd456b4dd95f9e53b'/>
<id>urn:sha1:9618e2ffd78aaa43a5815e1dd456b4dd95f9e53b</id>
<content type='text'>
Use u64_stats_sync infrastructure to implement 64bit rx stats.

(tx stats are addressed later)

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Acked-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: Enable 64-bit net device statistics on 32-bit architectures</title>
<updated>2010-06-12T22:51:22Z</updated>
<author>
<name>Ben Hutchings</name>
</author>
<published>2010-06-08T07:19:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=be1f3c2c027cc5ad735df6a45a542ed1db7ec48b'/>
<id>urn:sha1:be1f3c2c027cc5ad735df6a45a542ed1db7ec48b</id>
<content type='text'>
Use struct rtnl_link_stats64 as the statistics structure.

On 32-bit architectures, insert 32 bits of padding after/before each
field of struct net_device_stats to make its layout compatible with
struct rtnl_link_stats64.  Add an anonymous union in net_device; move
stats into the union and add struct rtnl_link_stats64 stats64.

Add net_device_ops::ndo_get_stats64, implementations of which will
return a pointer to struct rtnl_link_stats64.  Drivers that implement
this operation must not update the structure asynchronously.

Change dev_get_stats() to call ndo_get_stats64 if available, and to
return a pointer to struct rtnl_link_stats64.  Change callers of
dev_get_stats() accordingly.

Signed-off-by: Ben Hutchings &lt;bhutchings@solarflare.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: deliver skbs on inactive slaves to exact matches</title>
<updated>2010-06-11T05:23:34Z</updated>
<author>
<name>John Fastabend</name>
</author>
<published>2010-06-03T09:30:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=597a264b1a9c7e36d1728f677c66c5c1f7e3b837'/>
<id>urn:sha1:597a264b1a9c7e36d1728f677c66c5c1f7e3b837</id>
<content type='text'>
Currently, the accelerated receive path for VLAN's will
drop packets if the real device is an inactive slave and
is not one of the special pkts tested for in
skb_bond_should_drop().  This behavior is different then
the non-accelerated path and for pkts over a bonded vlan.

For example,

vlanx -&gt; bond0 -&gt; ethx

will be dropped in the vlan path and not delivered to any
packet handlers at all.  However,

bond0 -&gt; vlanx -&gt; ethx

and

bond0 -&gt; ethx

will be delivered to handlers that match the exact dev,
because the VLAN path checks the real_dev which is not a
slave and netif_recv_skb() doesn't drop frames but only
delivers them to exact matches.

This patch adds a sk_buff flag which is used for tagging
skbs that would previously been dropped and allows the
skb to continue to skb_netif_recv().  Here we add
logic to check for the deliver_no_wcard flag and if it
is set only deliver to handlers that match exactly.  This
makes both paths above consistent and gives pkt handlers
a way to identify skbs that come from inactive slaves.
Without this patch in some configurations skbs will be
delivered to handlers with exact matches and in others
be dropped out right in the vlan path.

I have tested the following 4 configurations in failover modes
and load balancing modes.

# bond0 -&gt; ethx

# vlanx -&gt; bond0 -&gt; ethx

# bond0 -&gt; vlanx -&gt; ethx

# bond0 -&gt; ethx
            |
  vlanx -&gt; --

Signed-off-by: John Fastabend &lt;john.r.fastabend@intel.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
