]> git.baikalelectronics.ru Git - kernel.git/commit
tipc: allow non-linear first fragment buffer
authorJon Paul Maloy <jon.maloy@ericsson.com>
Mon, 19 Oct 2015 15:33:00 +0000 (11:33 -0400)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 Oct 2015 02:08:24 +0000 (19:08 -0700)
commitd415598a4550a3f495539bf60e1795975f757210
treefc27cba7a71607103f6dcd3346fefb6f12c722ae
parent5f538839eca3f7501836c79b3045711a050f3486
tipc: allow non-linear first fragment buffer

The current code for message reassembly is erroneously assuming that
the the first arriving fragment buffer always is linear, and then goes
ahead resetting the fragment list of that buffer in anticipation of
more arriving fragments.

However, if the buffer already happens to be non-linear, we will
inadvertently drop the already attached fragment list, and later
on trig a BUG() in __pskb_pull_tail().

We see this happen when running fragmented TIPC multicast across UDP,
something made possible since
commit 38e17eaa07d7 ("tipc: add ip/udp media type")

We fix this by not resetting the fragment list when the buffer is non-
linear, and by initiatlizing our private fragment list tail pointer to
the tail of the existing fragment list.

Fixes: commit 38e17eaa07d7 ("tipc: add ip/udp media type")
Signed-off-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/msg.c