<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/net/netfilter/nfnetlink_queue.c, branch v2.6.31</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>nfnetlink_queue: Use rcu_barrier() on module unload.</title>
<updated>2009-06-10T08:11:23+00:00</updated>
<author>
<name>Jesper Dangaard Brouer</name>
<email>hawk@comx.dk</email>
</author>
<published>2009-06-08T03:11:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=67137f3cc727e4da0297ffd7bfade837aa15ecfa'/>
<id>67137f3cc727e4da0297ffd7bfade837aa15ecfa</id>
<content type='text'>
This module uses rcu_call() thus it should use rcu_barrier() on module unload.

Also fixed a trivial typo 'nfetlink' -&gt; 'nfnetlink' in comment.

Signed-off-by: Jesper Dangaard Brouer &lt;hawk@comx.dk&gt;
Acked-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Acked-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This module uses rcu_call() thus it should use rcu_barrier() on module unload.

Also fixed a trivial typo 'nfetlink' -&gt; 'nfnetlink' in comment.

Signed-off-by: Jesper Dangaard Brouer &lt;hawk@comx.dk&gt;
Acked-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Acked-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>netns: Use net_eq() to compare net-namespaces for optimization.</title>
<updated>2008-07-20T05:34:43+00:00</updated>
<author>
<name>YOSHIFUJI Hideaki</name>
<email>yoshfuji@linux-ipv6.org</email>
</author>
<published>2008-07-20T05:34:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=721499e8931c5732202481ae24f2dfbf9910f129'/>
<id>721499e8931c5732202481ae24f2dfbf9910f129</id>
<content type='text'>
Without CONFIG_NET_NS, namespace is always &amp;init_net.
Compiler will be able to omit namespace comparisons with this patch.

Signed-off-by: YOSHIFUJI Hideaki &lt;yoshfuji@linux-ipv6.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Without CONFIG_NET_NS, namespace is always &amp;init_net.
Compiler will be able to omit namespace comparisons with this patch.

Signed-off-by: YOSHIFUJI Hideaki &lt;yoshfuji@linux-ipv6.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>netfilter: {ip,ip6,nfnetlink}_queue: misc cleanups</title>
<updated>2008-06-09T23:00:45+00:00</updated>
<author>
<name>Rami Rosen</name>
<email>ramirose@gmail.com</email>
</author>
<published>2008-06-09T23:00:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=e64bda89b8fe81cce9b4a20885d2c204c2d52532'/>
<id>e64bda89b8fe81cce9b4a20885d2c204c2d52532</id>
<content type='text'>
- No need to perform data_len = 0 in the switch command, since data_len
  is initialized to 0 in the beginning of the ipq_build_packet_message()
  method.

- {ip,ip6}_queue: We can reach nlmsg_failure only from one place; skb is
  sure to be NULL when getting there; since skb is NULL, there is no need
  to check this fact and call kfree_skb().

Signed-off-by: Rami Rosen &lt;ramirose@gmail.com&gt;
Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- No need to perform data_len = 0 in the switch command, since data_len
  is initialized to 0 in the beginning of the ipq_build_packet_message()
  method.

- {ip,ip6}_queue: We can reach nlmsg_failure only from one place; skb is
  sure to be NULL when getting there; since skb is NULL, there is no need
  to check this fact and call kfree_skb().

Signed-off-by: Rami Rosen &lt;ramirose@gmail.com&gt;
Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>netfilter: {nfnetlink,ip,ip6}_queue: fix skb_over_panic when enlarging packets</title>
<updated>2008-04-29T10:16:34+00:00</updated>
<author>
<name>Arnaud Ebalard</name>
<email>arno@natisbad.org</email>
</author>
<published>2008-04-29T10:16:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=9a732ed6d0e126d4c8a818f42a13f3df11755bee'/>
<id>9a732ed6d0e126d4c8a818f42a13f3df11755bee</id>
<content type='text'>
While reinjecting *bigger* modified versions of IPv6 packets using
libnetfilter_queue, things work fine on a 2.6.24 kernel (2.6.22 too)
but I get the following on recents kernels (2.6.25, trace below is
against today's net-2.6 git tree):

skb_over_panic: text:c04fddb0 len:696 put:632 head:f7592c00 data:f7592c00 tail:0xf7592eb8 end:0xf7592e80 dev:eth0
------------[ cut here ]------------
invalid opcode: 0000 [#1] PREEMPT 
Process sendd (pid: 3657, ti=f6014000 task=f77c31d0 task.ti=f6014000)
Stack: c071e638 c04fddb0 000002b8 00000278 f7592c00 f7592c00 f7592eb8 f7592e80 
       f763c000 f6bc5200 f7592c40 f6015c34 c04cdbfc f6bc5200 00000278 f6015c60 
       c04fddb0 00000020 f72a10c0 f751b420 00000001 0000000a 000002b8 c065582c 
Call Trace:
 [&lt;c04fddb0&gt;] ? nfqnl_recv_verdict+0x1c0/0x2e0
 [&lt;c04cdbfc&gt;] ? skb_put+0x3c/0x40
 [&lt;c04fddb0&gt;] ? nfqnl_recv_verdict+0x1c0/0x2e0
 [&lt;c04fd115&gt;] ? nfnetlink_rcv_msg+0xf5/0x160
 [&lt;c04fd03e&gt;] ? nfnetlink_rcv_msg+0x1e/0x160
 [&lt;c04fd020&gt;] ? nfnetlink_rcv_msg+0x0/0x160
 [&lt;c04f8ed7&gt;] ? netlink_rcv_skb+0x77/0xa0
 [&lt;c04fcefc&gt;] ? nfnetlink_rcv+0x1c/0x30
 [&lt;c04f8c73&gt;] ? netlink_unicast+0x243/0x2b0
 [&lt;c04cfaba&gt;] ? memcpy_fromiovec+0x4a/0x70
 [&lt;c04f9406&gt;] ? netlink_sendmsg+0x1c6/0x270
 [&lt;c04c8244&gt;] ? sock_sendmsg+0xc4/0xf0
 [&lt;c011970d&gt;] ? set_next_entity+0x1d/0x50
 [&lt;c0133a80&gt;] ? autoremove_wake_function+0x0/0x40
 [&lt;c0118f9e&gt;] ? __wake_up_common+0x3e/0x70
 [&lt;c0342fbf&gt;] ? n_tty_receive_buf+0x34f/0x1280
 [&lt;c011d308&gt;] ? __wake_up+0x68/0x70
 [&lt;c02cea47&gt;] ? copy_from_user+0x37/0x70
 [&lt;c04cfd7c&gt;] ? verify_iovec+0x2c/0x90
 [&lt;c04c837a&gt;] ? sys_sendmsg+0x10a/0x230
 [&lt;c011967a&gt;] ? __dequeue_entity+0x2a/0xa0
 [&lt;c011970d&gt;] ? set_next_entity+0x1d/0x50
 [&lt;c0345397&gt;] ? pty_write+0x47/0x60
 [&lt;c033d59b&gt;] ? tty_default_put_char+0x1b/0x20
 [&lt;c011d2e9&gt;] ? __wake_up+0x49/0x70
 [&lt;c033df99&gt;] ? tty_ldisc_deref+0x39/0x90
 [&lt;c033ff20&gt;] ? tty_write+0x1a0/0x1b0
 [&lt;c04c93af&gt;] ? sys_socketcall+0x7f/0x260
 [&lt;c0102ff9&gt;] ? sysenter_past_esp+0x6a/0x91
 [&lt;c05f0000&gt;] ? snd_intel8x0m_probe+0x270/0x6e0
 =======================
Code: 00 00 89 5c 24 14 8b 98 9c 00 00 00 89 54 24 0c 89 5c 24 10 8b 40 50 89 4c 24 04 c7 04 24 38 e6 71 c0 89 44 24 08 e8 c4 46 c5 ff &lt;0f&gt; 0b eb fe 55 89 e5 56 89 d6 53 89 c3 83 ec 0c 8b 40 50 39 d0 
EIP: [&lt;c04ccdfc&gt;] skb_over_panic+0x5c/0x60 SS:ESP 0068:f6015bf8


Looking at the code, I ended up in nfq_mangle() function (called by
nfqnl_recv_verdict()) which performs a call to skb_copy_expand() due to
the increased size of data passed to the function. AFAICT, it should ask
for 'diff' instead of 'diff - skb_tailroom(e-&gt;skb)'. Because the
resulting sk_buff has not enough space to support the skb_put(skb, diff)
call a few lines later, this results in the call to skb_over_panic().

The patch below asks for allocation of a copy with enough space for
mangled packet and the same amount of headroom as old sk_buff. While
looking at how the regression appeared (e2b58a67), I noticed the same
pattern in ipq_mangle_ipv6() and ipq_mangle_ipv4(). The patch corrects
those locations too.

Tested with bigger reinjected IPv6 packets (nfqnl_mangle() path), things
are ok (2.6.25 and today's net-2.6 git tree).

Signed-off-by: Arnaud Ebalard &lt;arno@natisbad.org&gt;
Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
While reinjecting *bigger* modified versions of IPv6 packets using
libnetfilter_queue, things work fine on a 2.6.24 kernel (2.6.22 too)
but I get the following on recents kernels (2.6.25, trace below is
against today's net-2.6 git tree):

skb_over_panic: text:c04fddb0 len:696 put:632 head:f7592c00 data:f7592c00 tail:0xf7592eb8 end:0xf7592e80 dev:eth0
------------[ cut here ]------------
invalid opcode: 0000 [#1] PREEMPT 
Process sendd (pid: 3657, ti=f6014000 task=f77c31d0 task.ti=f6014000)
Stack: c071e638 c04fddb0 000002b8 00000278 f7592c00 f7592c00 f7592eb8 f7592e80 
       f763c000 f6bc5200 f7592c40 f6015c34 c04cdbfc f6bc5200 00000278 f6015c60 
       c04fddb0 00000020 f72a10c0 f751b420 00000001 0000000a 000002b8 c065582c 
Call Trace:
 [&lt;c04fddb0&gt;] ? nfqnl_recv_verdict+0x1c0/0x2e0
 [&lt;c04cdbfc&gt;] ? skb_put+0x3c/0x40
 [&lt;c04fddb0&gt;] ? nfqnl_recv_verdict+0x1c0/0x2e0
 [&lt;c04fd115&gt;] ? nfnetlink_rcv_msg+0xf5/0x160
 [&lt;c04fd03e&gt;] ? nfnetlink_rcv_msg+0x1e/0x160
 [&lt;c04fd020&gt;] ? nfnetlink_rcv_msg+0x0/0x160
 [&lt;c04f8ed7&gt;] ? netlink_rcv_skb+0x77/0xa0
 [&lt;c04fcefc&gt;] ? nfnetlink_rcv+0x1c/0x30
 [&lt;c04f8c73&gt;] ? netlink_unicast+0x243/0x2b0
 [&lt;c04cfaba&gt;] ? memcpy_fromiovec+0x4a/0x70
 [&lt;c04f9406&gt;] ? netlink_sendmsg+0x1c6/0x270
 [&lt;c04c8244&gt;] ? sock_sendmsg+0xc4/0xf0
 [&lt;c011970d&gt;] ? set_next_entity+0x1d/0x50
 [&lt;c0133a80&gt;] ? autoremove_wake_function+0x0/0x40
 [&lt;c0118f9e&gt;] ? __wake_up_common+0x3e/0x70
 [&lt;c0342fbf&gt;] ? n_tty_receive_buf+0x34f/0x1280
 [&lt;c011d308&gt;] ? __wake_up+0x68/0x70
 [&lt;c02cea47&gt;] ? copy_from_user+0x37/0x70
 [&lt;c04cfd7c&gt;] ? verify_iovec+0x2c/0x90
 [&lt;c04c837a&gt;] ? sys_sendmsg+0x10a/0x230
 [&lt;c011967a&gt;] ? __dequeue_entity+0x2a/0xa0
 [&lt;c011970d&gt;] ? set_next_entity+0x1d/0x50
 [&lt;c0345397&gt;] ? pty_write+0x47/0x60
 [&lt;c033d59b&gt;] ? tty_default_put_char+0x1b/0x20
 [&lt;c011d2e9&gt;] ? __wake_up+0x49/0x70
 [&lt;c033df99&gt;] ? tty_ldisc_deref+0x39/0x90
 [&lt;c033ff20&gt;] ? tty_write+0x1a0/0x1b0
 [&lt;c04c93af&gt;] ? sys_socketcall+0x7f/0x260
 [&lt;c0102ff9&gt;] ? sysenter_past_esp+0x6a/0x91
 [&lt;c05f0000&gt;] ? snd_intel8x0m_probe+0x270/0x6e0
 =======================
Code: 00 00 89 5c 24 14 8b 98 9c 00 00 00 89 54 24 0c 89 5c 24 10 8b 40 50 89 4c 24 04 c7 04 24 38 e6 71 c0 89 44 24 08 e8 c4 46 c5 ff &lt;0f&gt; 0b eb fe 55 89 e5 56 89 d6 53 89 c3 83 ec 0c 8b 40 50 39 d0 
EIP: [&lt;c04ccdfc&gt;] skb_over_panic+0x5c/0x60 SS:ESP 0068:f6015bf8


Looking at the code, I ended up in nfq_mangle() function (called by
nfqnl_recv_verdict()) which performs a call to skb_copy_expand() due to
the increased size of data passed to the function. AFAICT, it should ask
for 'diff' instead of 'diff - skb_tailroom(e-&gt;skb)'. Because the
resulting sk_buff has not enough space to support the skb_put(skb, diff)
call a few lines later, this results in the call to skb_over_panic().

The patch below asks for allocation of a copy with enough space for
mangled packet and the same amount of headroom as old sk_buff. While
looking at how the regression appeared (e2b58a67), I noticed the same
pattern in ipq_mangle_ipv6() and ipq_mangle_ipv4(). The patch corrects
those locations too.

Tested with bigger reinjected IPv6 packets (nfqnl_mangle() path), things
are ok (2.6.25 and today's net-2.6 git tree).

Signed-off-by: Arnaud Ebalard &lt;arno@natisbad.org&gt;
Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6</title>
<updated>2008-03-28T01:48:56+00:00</updated>
<author>
<name>David S. Miller</name>
<email>davem@davemloft.net</email>
</author>
<published>2008-03-28T01:48:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8e8e43843ba3ced0c657cbc0fdb10644ec60f772'/>
<id>8e8e43843ba3ced0c657cbc0fdb10644ec60f772</id>
<content type='text'>
Conflicts:

	drivers/net/usb/rndis_host.c
	drivers/net/wireless/b43/dma.c
	net/ipv6/ndisc.c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Conflicts:

	drivers/net/usb/rndis_host.c
	drivers/net/wireless/b43/dma.c
	net/ipv6/ndisc.c
</pre>
</div>
</content>
</entry>
<entry>
<title>[NETFILTER]: Replate direct proc_fops assignment with proc_create call.</title>
<updated>2008-03-27T23:55:53+00:00</updated>
<author>
<name>Denis V. Lunev</name>
<email>den@openvz.org</email>
</author>
<published>2008-03-27T23:55:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8eeee8b152ae6bbe181518efaf62ba8e9c613693'/>
<id>8eeee8b152ae6bbe181518efaf62ba8e9c613693</id>
<content type='text'>
This elliminates infamous race during module loading when one could lookup
proc entry without proc_fops assigned.

Signed-off-by: Denis V. Lunev &lt;den@openvz.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This elliminates infamous race during module loading when one could lookup
proc entry without proc_fops assigned.

Signed-off-by: Denis V. Lunev &lt;den@openvz.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[NET] NETNS: Omit net_device-&gt;nd_net without CONFIG_NET_NS.</title>
<updated>2008-03-25T19:39:53+00:00</updated>
<author>
<name>YOSHIFUJI Hideaki</name>
<email>yoshfuji@linux-ipv6.org</email>
</author>
<published>2008-03-25T12:47:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=c346dca10840a874240c78efe3f39acf4312a1f2'/>
<id>c346dca10840a874240c78efe3f39acf4312a1f2</id>
<content type='text'>
Introduce per-net_device inlines: dev_net(), dev_net_set().
Without CONFIG_NET_NS, no namespace other than &amp;init_net exists.
Let's explicitly define them to help compiler optimizations.

Signed-off-by: YOSHIFUJI Hideaki &lt;yoshfuji@linux-ipv6.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Introduce per-net_device inlines: dev_net(), dev_net_set().
Without CONFIG_NET_NS, no namespace other than &amp;init_net exists.
Let's explicitly define them to help compiler optimizations.

Signed-off-by: YOSHIFUJI Hideaki &lt;yoshfuji@linux-ipv6.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[NETFILTER]: nfnetlink_queue: fix EPERM when binding/unbinding and instance 0 exists</title>
<updated>2008-03-10T23:44:36+00:00</updated>
<author>
<name>Patrick McHardy</name>
<email>kaber@trash.net</email>
</author>
<published>2008-03-10T23:44:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=914afea84e3e20cdbcd040f8387a0e6ef20ffc97'/>
<id>914afea84e3e20cdbcd040f8387a0e6ef20ffc97</id>
<content type='text'>
Similar to the nfnetlink_log problem, nfnetlink_queue incorrectly
returns -EPERM when binding or unbinding to an address family and
queueing instance 0 exists and is owned by a different process. Unlike
nfnetlink_log it previously completes the operation, but it is still
incorrect.

Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Similar to the nfnetlink_log problem, nfnetlink_queue incorrectly
returns -EPERM when binding or unbinding to an address family and
queueing instance 0 exists and is owned by a different process. Unlike
nfnetlink_log it previously completes the operation, but it is still
incorrect.

Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[NETFILTER]: nfnetlink_queue: fix computation of allocated size for netlink skb.</title>
<updated>2008-03-10T23:41:43+00:00</updated>
<author>
<name>Eric Leblond</name>
<email>eric@inl.fr</email>
</author>
<published>2008-03-10T23:41:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=cabaa9bfb01eb4cee97ffb8a18405f4c5175d3d9'/>
<id>cabaa9bfb01eb4cee97ffb8a18405f4c5175d3d9</id>
<content type='text'>
Size of the netlink skb was wrongly computed because the formula was using
NLMSG_ALIGN instead of NLMSG_SPACE. NLMSG_ALIGN does not add the room for
netlink header as NLMSG_SPACE does. This was causing a failure of message
building in some cases.

On my test system, all messages for packets in range [8*k+41, 8*k+48] where k
is an integer were invalid and the corresponding packets were dropped.

Signed-off-by: Eric Leblond &lt;eric@inl.fr&gt;
Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Size of the netlink skb was wrongly computed because the formula was using
NLMSG_ALIGN instead of NLMSG_SPACE. NLMSG_ALIGN does not add the room for
netlink header as NLMSG_SPACE does. This was causing a failure of message
building in some cases.

On my test system, all messages for packets in range [8*k+41, 8*k+48] where k
is an integer were invalid and the corresponding packets were dropped.

Signed-off-by: Eric Leblond &lt;eric@inl.fr&gt;
Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[NETFILTER]: {ip,ip6,nfnetlink}_queue: fix SKB_LINEAR_ASSERT when mangling packet data</title>
<updated>2008-02-20T01:17:52+00:00</updated>
<author>
<name>Patrick McHardy</name>
<email>kaber@trash.net</email>
</author>
<published>2008-02-20T01:17:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=e2b58a67b91dec07dfb40ca2056c64011ce8489d'/>
<id>e2b58a67b91dec07dfb40ca2056c64011ce8489d</id>
<content type='text'>
As reported by Tomas Simonaitis &lt;tomas.simonaitis@gmail.com&gt;,
inserting new data in skbs queued over {ip,ip6,nfnetlink}_queue
triggers a SKB_LINEAR_ASSERT in skb_put().

Going back through the git history, it seems this bug is present since
at least 2.6.12-rc2, probably even since the removal of
skb_linearize() for netfilter.

Linearize non-linear skbs through skb_copy_expand() when enlarging
them.  Tested by Thomas, fixes bugzilla #9933.

Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As reported by Tomas Simonaitis &lt;tomas.simonaitis@gmail.com&gt;,
inserting new data in skbs queued over {ip,ip6,nfnetlink}_queue
triggers a SKB_LINEAR_ASSERT in skb_put().

Going back through the git history, it seems this bug is present since
at least 2.6.12-rc2, probably even since the removal of
skb_linearize() for netfilter.

Linearize non-linear skbs through skb_copy_expand() when enlarging
them.  Tested by Thomas, fixes bugzilla #9933.

Signed-off-by: Patrick McHardy &lt;kaber@trash.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</pre>
</div>
</content>
</entry>
</feed>
