<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/net/packet, branch v3.6.9</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v3.6.9</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v3.6.9'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2012-08-23T16:27:12Z</updated>
<entry>
<title>af_packet: match_fanout_group() can be static</title>
<updated>2012-08-23T16:27:12Z</updated>
<author>
<name>Fengguang Wu</name>
<email>fengguang.wu@intel.com</email>
</author>
<published>2012-08-23T11:51:21Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=a0dfb2634e5671770f598cda08002d8cda66ac77'/>
<id>urn:sha1:a0dfb2634e5671770f598cda08002d8cda66ac77</id>
<content type='text'>
cc: Eric Leblond &lt;eric@regit.org&gt;
Signed-off-by: Fengguang Wu &lt;fengguang.wu@intel.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>af_packet: don't emit packet on orig fanout group</title>
<updated>2012-08-20T09:37:29Z</updated>
<author>
<name>Eric Leblond</name>
<email>eric@regit.org</email>
</author>
<published>2012-08-16T22:02:58Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=c0de08d04215031d68fa13af36f347a6cfa252ca'/>
<id>urn:sha1:c0de08d04215031d68fa13af36f347a6cfa252ca</id>
<content type='text'>
If a packet is emitted on one socket in one group of fanout sockets,
it is transmitted again. It is thus read again on one of the sockets
of the fanout group. This result in a loop for software which
generate packets when receiving one.
This retransmission is not the intended behavior: a fanout group
must behave like a single socket. The packet should not be
transmitted on a socket if it originates from a socket belonging
to the same fanout group.

This patch fixes the issue by changing the transmission check to
take fanout group info account.

Reported-by: Aleksandr Kotov &lt;a1k@mail.ru&gt;
Signed-off-by: Eric Leblond &lt;eric@regit.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>af_packet: remove BUG statement in tpacket_destruct_skb</title>
<updated>2012-08-12T20:42:17Z</updated>
<author>
<name>danborkmann@iogearbox.net</name>
<email>danborkmann@iogearbox.net</email>
</author>
<published>2012-08-10T22:48:54Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=7f5c3e3a80e6654cf48dfba7cf94f88c6b505467'/>
<id>urn:sha1:7f5c3e3a80e6654cf48dfba7cf94f88c6b505467</id>
<content type='text'>
Here's a quote of the comment about the BUG macro from asm-generic/bug.h:

 Don't use BUG() or BUG_ON() unless there's really no way out; one
 example might be detecting data structure corruption in the middle
 of an operation that can't be backed out of.  If the (sub)system
 can somehow continue operating, perhaps with reduced functionality,
 it's probably not BUG-worthy.

 If you're tempted to BUG(), think again:  is completely giving up
 really the *only* solution?  There are usually better options, where
 users don't need to reboot ASAP and can mostly shut down cleanly.

In our case, the status flag of a ring buffer slot is managed from both sides,
the kernel space and the user space. This means that even though the kernel
side might work as expected, the user space screws up and changes this flag
right between the send(2) is triggered when the flag is changed to
TP_STATUS_SENDING and a given skb is destructed after some time. Then, this
will hit the BUG macro. As David suggested, the best solution is to simply
remove this statement since it cannot be used for kernel side internal
consistency checks. I've tested it and the system still behaves /stable/ in
this case, so in accordance with the above comment, we should rather remove it.

Signed-off-by: Daniel Borkmann &lt;daniel.borkmann@tik.ee.ethz.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>af_packet: Quiet sparse noise about using plain integer as NULL pointer</title>
<updated>2012-08-08T22:43:22Z</updated>
<author>
<name>Ying Xue</name>
<email>ying.xue@windriver.com</email>
</author>
<published>2012-08-06T16:27:10Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=99aa3473e672ca610905838997fa018b95cd643f'/>
<id>urn:sha1:99aa3473e672ca610905838997fa018b95cd643f</id>
<content type='text'>
Quiets the sparse warning:
warning: Using plain integer as NULL pointer

Signed-off-by: Ying Xue &lt;ying.xue@windriver.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: added support for 40GbE link.</title>
<updated>2012-06-27T22:42:24Z</updated>
<author>
<name>parav.pandit@emulex.com</name>
<email>parav.pandit@emulex.com</email>
</author>
<published>2012-06-27T03:56:12Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=e440cf2ca0a1b075c64016240d46c3aa9d877bbf'/>
<id>urn:sha1:e440cf2ca0a1b075c64016240d46c3aa9d877bbf</id>
<content type='text'>
1. removed code replication for tov calculation for 1G, 10G and
made is common for speed &gt; 1G (1G, 10G, 40G, 100G).
2. defines values for #4 different 40G Phys (KR4, LF4, SR4, CR4)

Signed-off-by: Parav Pandit &lt;parav.pandit@emulex.com&gt;
Reviewed-by: Ben Hutchings &lt;bhutchings@solarflare.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>af_packet: use sizeof instead of constant in spkt_device</title>
<updated>2012-06-11T23:51:51Z</updated>
<author>
<name>danborkmann@iogearbox.net</name>
<email>danborkmann@iogearbox.net</email>
</author>
<published>2012-06-10T08:59:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=de74e92aa8a44d0b80a53601dc4f6dd6afcb8453'/>
<id>urn:sha1:de74e92aa8a44d0b80a53601dc4f6dd6afcb8453</id>
<content type='text'>
This small patch removes access to the last element of the spkt_device
array through a constant. Instead, it is accessed by sizeof() to respect
possible changes in if_packet.h.

Signed-off-by: Daniel Borkmann &lt;daniel.borkmann@tik.ee.ethz.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: Remove casts to same type</title>
<updated>2012-06-04T15:45:11Z</updated>
<author>
<name>Joe Perches</name>
<email>joe@perches.com</email>
</author>
<published>2012-06-03T17:41:40Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=e3192690a3c889767d1161b228374f4926d92af0'/>
<id>urn:sha1:e3192690a3c889767d1161b228374f4926d92af0</id>
<content type='text'>
Adding casts of objects to the same type is unnecessary
and confusing for a human reader.

For example, this cast:

	int y;
	int *p = (int *)&amp;y;

I used the coccinelle script below to find and remove these
unnecessary casts.  I manually removed the conversions this
script produces of casts with __force and __user.

@@
type T;
T *p;
@@

-	(T *)p
+	p

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>af_packet: packet_getsockopt() cleanup</title>
<updated>2012-04-21T20:36:42Z</updated>
<author>
<name>Eric Dumazet</name>
<email>edumazet@google.com</email>
</author>
<published>2012-04-19T21:56:11Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=c06fff6e175729f0d89201c98d21e55c2bf1a850'/>
<id>urn:sha1:c06fff6e175729f0d89201c98d21e55c2bf1a850</id>
<content type='text'>
Factorize code, since most fetched values are int type.

Signed-off-by: Eric Dumazet &lt;edumazet@google.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>packet: dont drop packet but consume it</title>
<updated>2012-04-19T18:23:55Z</updated>
<author>
<name>Eric Dumazet</name>
<email>edumazet@google.com</email>
</author>
<published>2012-04-19T02:24:42Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=abc4e4fa29eb81f874d4ef3c6bafcf5ad6f90b07'/>
<id>urn:sha1:abc4e4fa29eb81f874d4ef3c6bafcf5ad6f90b07</id>
<content type='text'>
When we need to clone skb, we dont drop a packet.
Call consume_skb() to not confuse dropwatch.

Signed-off-by: Eric Dumazet &lt;edumazet@google.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: cleanup unsigned to unsigned int</title>
<updated>2012-04-15T16:44:40Z</updated>
<author>
<name>Eric Dumazet</name>
<email>eric.dumazet@gmail.com</email>
</author>
<published>2012-04-15T05:58:06Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=95c961747284a6b83a5e2d81240e214b0fa3464d'/>
<id>urn:sha1:95c961747284a6b83a5e2d81240e214b0fa3464d</id>
<content type='text'>
Use of "unsigned int" is preferred to bare "unsigned" in net tree.

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
