Staging: batman-adv: Aggregate batman packets directly in skb
authorSven Eckelmann <sven.eckelmann@gmx.de>
Sat, 4 Sep 2010 23:58:30 +0000 (01:58 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Sun, 5 Sep 2010 07:29:47 +0000 (00:29 -0700)
commitb706007b8903bb3a6ada97665653ba522ae49bb2
tree737bd7b23a427b6437528bbcdd3954d823bafa3f
parent43bfee7693f458e1ef120d2b310ef0288ab747e8
Staging: batman-adv: Aggregate batman packets directly in skb

All originator messages are send through aggregation buffers. Those
buffers can directly be allocated as skb to reduce the cost of
allocation an extra buffer and copying them to a new allocated skb
directly before it gets send.

Now only the skb must be cloned in case of send_packet_to_if as it gets
called by send_packet for each interface. Non-primary ogms must not
cloned at all because they will only send once and the forward_packet
structure is freed by send_outstanding_bat_packet afterwards.

Reported-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/batman-adv/aggregation.c
drivers/staging/batman-adv/send.c
drivers/staging/batman-adv/types.h