]> git.baikalelectronics.ru Git - kernel.git/commit
tipc: introduce new function tipc_msg_create()
authorJon Paul Maloy <jon.maloy@ericsson.com>
Fri, 22 Aug 2014 22:09:06 +0000 (18:09 -0400)
committerDavid S. Miller <davem@davemloft.net>
Sat, 23 Aug 2014 18:18:33 +0000 (11:18 -0700)
commitc23b26aecd30e1f223a200bb7d469c45919aef54
treeecb081688de3079314e22dbb378892e75334992e
parent0af484232624541a984eed9309c19b66b748af8b
tipc: introduce new function tipc_msg_create()

The function tipc_msg_init() has turned out to be of limited value
in many cases. It take too few parameters to be usable for creating
a complete message, it makes too many assumptions about what the
message should be used for, and it does not allocate any buffer to
be returned to the caller.

Therefore, we now introduce the new function tipc_msg_create(), which
takes all the parameters needed to create a full message, and returns
a buffer of the requested size. The new function will be very useful
for the changes we will be doing in later commits in this series.

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