]> git.baikalelectronics.ru Git - kernel.git/commit
tipc: eliminate unnecessary linearization of incoming buffers
authorJon Paul Maloy <jon.maloy@ericsson.com>
Fri, 13 Mar 2015 20:08:07 +0000 (16:08 -0400)
committerDavid S. Miller <davem@davemloft.net>
Sat, 14 Mar 2015 18:38:32 +0000 (14:38 -0400)
commit7766824537334c6b198b2b5f068597e9671d3729
tree1253880332cf983760ba27a157f6b77aa11859e4
parent0a7c9ca6e5ccf217827c38d9e9d42ffde0b713ce
tipc: eliminate unnecessary linearization of incoming buffers

Currently, TIPC linearizes all incoming buffers directly at reception
before passing them upwards in the stack. This is clearly a waste of
CPU resources, and must be avoided.

In this commit, we eliminate this unnecessary linearization. We still
ensure that at least the message header is linear, and that the buffer
is linearized where this is still needed, i.e. when unbundling and when
reversing messages.

In addition, we ensure that fragmented messages are validated after
reassembly before delivering them upwards in the stack.

Reviewed-by: Erik Hugne <erik.hugne@ericsson.com>
Reviewed-by: Ying Xue <ying.xue@windriver.com>
Signed-off-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/link.c
net/tipc/msg.c