On Tue, Apr 16, 2013 at 11:26:34PM +0800, Marek Lindner wrote:
Instead of generating TT specific packets the TVLV unicast API is used to send translation table data.
Signed-off-by: Marek Lindner lindner_marek@yahoo.de
[...]
- if (batadv_send_skb_to_orig(skb, dst_orig_node, NULL))
ret = 0;
- batadv_tvlv_unicast_send(bat_priv, primary_if->net_dev->dev_addr,
dst_orig_node->orig, BATADV_TVLV_TT, 1,
(unsigned char *)tvlv_tt_data,
^^^^^^^^^^^^^^^^^ You should remove this cast since the function expects a void *
sizeof(*tvlv_tt_data));
- ret = true;
[...]
- if (batadv_send_skb_to_orig(skb, res_dst_orig_node, NULL))
ret = true;
- batadv_tvlv_unicast_send(bat_priv, req_dst_orig_node->orig,
req_src, BATADV_TVLV_TT, 1,
(unsigned char *)tvlv_tt_data,
same here.
sizeof(*tvlv_tt_data) + tt_len);
- ret = true; goto out;
[...]
- if (batadv_send_skb_to_orig(skb, orig_node, NULL))
ret = true;
- batadv_tvlv_unicast_send(bat_priv, primary_if->net_dev->dev_addr,
req_src, BATADV_TVLV_TT, 1,
(unsigned char *)tvlv_tt_data,
same here².
sizeof(*tvlv_tt_data) + tt_len);
Cheers,