aboutsummaryrefslogtreecommitdiffstats
path: root/net/batman-adv/send.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/batman-adv/send.c')
-rw-r--r--net/batman-adv/send.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/net/batman-adv/send.c b/net/batman-adv/send.c
index 79f8973810c0..bceb3d72e5c3 100644
--- a/net/batman-adv/send.c
+++ b/net/batman-adv/send.c
@@ -33,8 +33,8 @@ static void send_outstanding_bcast_packet(struct work_struct *work);
33 33
34/* send out an already prepared packet to the given address via the 34/* send out an already prepared packet to the given address via the
35 * specified batman interface */ 35 * specified batman interface */
36int send_skb_packet(struct sk_buff *skb, struct hard_iface *hard_iface, 36int batadv_send_skb_packet(struct sk_buff *skb, struct hard_iface *hard_iface,
37 const uint8_t *dst_addr) 37 const uint8_t *dst_addr)
38{ 38{
39 struct ethhdr *ethhdr; 39 struct ethhdr *ethhdr;
40 40
@@ -77,7 +77,7 @@ send_skb_err:
77 return NET_XMIT_DROP; 77 return NET_XMIT_DROP;
78} 78}
79 79
80void schedule_bat_ogm(struct hard_iface *hard_iface) 80void batadv_schedule_bat_ogm(struct hard_iface *hard_iface)
81{ 81{
82 struct bat_priv *bat_priv = netdev_priv(hard_iface->soft_iface); 82 struct bat_priv *bat_priv = netdev_priv(hard_iface->soft_iface);
83 83
@@ -133,8 +133,9 @@ static void _add_bcast_packet_to_list(struct bat_priv *bat_priv,
133 * 133 *
134 * The skb is not consumed, so the caller should make sure that the 134 * The skb is not consumed, so the caller should make sure that the
135 * skb is freed. */ 135 * skb is freed. */
136int add_bcast_packet_to_list(struct bat_priv *bat_priv, 136int batadv_add_bcast_packet_to_list(struct bat_priv *bat_priv,
137 const struct sk_buff *skb, unsigned long delay) 137 const struct sk_buff *skb,
138 unsigned long delay)
138{ 139{
139 struct hard_iface *primary_if = NULL; 140 struct hard_iface *primary_if = NULL;
140 struct forw_packet *forw_packet; 141 struct forw_packet *forw_packet;
@@ -211,7 +212,8 @@ static void send_outstanding_bcast_packet(struct work_struct *work)
211 /* send a copy of the saved skb */ 212 /* send a copy of the saved skb */
212 skb1 = skb_clone(forw_packet->skb, GFP_ATOMIC); 213 skb1 = skb_clone(forw_packet->skb, GFP_ATOMIC);
213 if (skb1) 214 if (skb1)
214 send_skb_packet(skb1, hard_iface, broadcast_addr); 215 batadv_send_skb_packet(skb1, hard_iface,
216 broadcast_addr);
215 } 217 }
216 rcu_read_unlock(); 218 rcu_read_unlock();
217 219
@@ -229,7 +231,7 @@ out:
229 atomic_inc(&bat_priv->bcast_queue_left); 231 atomic_inc(&bat_priv->bcast_queue_left);
230} 232}
231 233
232void send_outstanding_bat_ogm_packet(struct work_struct *work) 234void batadv_send_outstanding_bat_ogm_packet(struct work_struct *work)
233{ 235{
234 struct delayed_work *delayed_work = 236 struct delayed_work *delayed_work =
235 container_of(work, struct delayed_work, work); 237 container_of(work, struct delayed_work, work);
@@ -253,7 +255,7 @@ void send_outstanding_bat_ogm_packet(struct work_struct *work)
253 * shutting down 255 * shutting down
254 */ 256 */
255 if (forw_packet->own) 257 if (forw_packet->own)
256 schedule_bat_ogm(forw_packet->if_incoming); 258 batadv_schedule_bat_ogm(forw_packet->if_incoming);
257 259
258out: 260out:
259 /* don't count own packet */ 261 /* don't count own packet */
@@ -263,8 +265,8 @@ out:
263 forw_packet_free(forw_packet); 265 forw_packet_free(forw_packet);
264} 266}
265 267
266void purge_outstanding_packets(struct bat_priv *bat_priv, 268void batadv_purge_outstanding_packets(struct bat_priv *bat_priv,
267 const struct hard_iface *hard_iface) 269 const struct hard_iface *hard_iface)
268{ 270{
269 struct forw_packet *forw_packet; 271 struct forw_packet *forw_packet;
270 struct hlist_node *tmp_node, *safe_tmp_node; 272 struct hlist_node *tmp_node, *safe_tmp_node;