X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=net%2Fbatman-adv%2Fsend.c;h=263cfd1ccee78dfdf66c0f102d66301b8700a46d;hb=150a8dcf109f68f322bf112c7604f2d950303f00;hp=a67cffde37ae62c4bcc5ae2833bd0634e4daa3f0;hpb=0d4a42f6bd298e826620585e766a154ab460617a;p=~andy%2Flinux diff --git a/net/batman-adv/send.c b/net/batman-adv/send.c index a67cffde37a..263cfd1ccee 100644 --- a/net/batman-adv/send.c +++ b/net/batman-adv/send.c @@ -27,6 +27,7 @@ #include "vis.h" #include "gateway_common.h" #include "originator.h" +#include "network-coding.h" #include @@ -39,6 +40,7 @@ int batadv_send_skb_packet(struct sk_buff *skb, struct batadv_hard_iface *hard_iface, const uint8_t *dst_addr) { + struct batadv_priv *bat_priv = netdev_priv(hard_iface->soft_iface); struct ethhdr *ethhdr; if (hard_iface->if_status != BATADV_IF_ACTIVE) @@ -70,6 +72,9 @@ int batadv_send_skb_packet(struct sk_buff *skb, skb->dev = hard_iface->net_dev; + /* Save a clone of the skb to use when decoding coded packets */ + batadv_nc_skb_store_for_decoding(bat_priv, skb); + /* dev_queue_xmit() returns a negative result on error. However on * congestion and traffic shaping, it drops and returns NET_XMIT_DROP * (which is > 0). This will not be treated as an error.