Skip to content

Commit 0f546ff

Browse files
committed
Merge tag 'batadv-net-for-davem-20171215' of git://git.open-mesh.org/linux-merge
Simon Wunderlich says: ==================== Here are some batman-adv bugfixes: - Initialize the fragment headers, by Sven Eckelmann - Fix a NULL check in BATMAN V, by Sven Eckelmann - Fix kernel doc for the time_setup() change, by Sven Eckelmann - Use the right lock in BATMAN IV OGM Update, by Sven Eckelmann ==================== Signed-off-by: David S. Miller <[email protected]>
2 parents fccff08 + 5ba7dcf commit 0f546ff

File tree

4 files changed

+7
-5
lines changed

4 files changed

+7
-5
lines changed

net/batman-adv/bat_iv_ogm.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1214,7 +1214,7 @@ static bool batadv_iv_ogm_calc_tq(struct batadv_orig_node *orig_node,
12141214
orig_node->last_seen = jiffies;
12151215

12161216
/* find packet count of corresponding one hop neighbor */
1217-
spin_lock_bh(&orig_node->bat_iv.ogm_cnt_lock);
1217+
spin_lock_bh(&orig_neigh_node->bat_iv.ogm_cnt_lock);
12181218
if_num = if_incoming->if_num;
12191219
orig_eq_count = orig_neigh_node->bat_iv.bcast_own_sum[if_num];
12201220
neigh_ifinfo = batadv_neigh_ifinfo_new(neigh_node, if_outgoing);
@@ -1224,7 +1224,7 @@ static bool batadv_iv_ogm_calc_tq(struct batadv_orig_node *orig_node,
12241224
} else {
12251225
neigh_rq_count = 0;
12261226
}
1227-
spin_unlock_bh(&orig_node->bat_iv.ogm_cnt_lock);
1227+
spin_unlock_bh(&orig_neigh_node->bat_iv.ogm_cnt_lock);
12281228

12291229
/* pay attention to not get a value bigger than 100 % */
12301230
if (orig_eq_count > neigh_rq_count)

net/batman-adv/bat_v.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -814,7 +814,7 @@ static bool batadv_v_gw_is_eligible(struct batadv_priv *bat_priv,
814814
}
815815

816816
orig_gw = batadv_gw_node_get(bat_priv, orig_node);
817-
if (!orig_node)
817+
if (!orig_gw)
818818
goto out;
819819

820820
if (batadv_v_gw_throughput_get(orig_gw, &orig_throughput) < 0)

net/batman-adv/fragmentation.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -499,6 +499,8 @@ int batadv_frag_send_packet(struct sk_buff *skb,
499499
*/
500500
if (skb->priority >= 256 && skb->priority <= 263)
501501
frag_header.priority = skb->priority - 256;
502+
else
503+
frag_header.priority = 0;
502504

503505
ether_addr_copy(frag_header.orig, primary_if->net_dev->dev_addr);
504506
ether_addr_copy(frag_header.dest, orig_node->orig);

net/batman-adv/tp_meter.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -482,7 +482,7 @@ static void batadv_tp_reset_sender_timer(struct batadv_tp_vars *tp_vars)
482482

483483
/**
484484
* batadv_tp_sender_timeout - timer that fires in case of packet loss
485-
* @arg: address of the related tp_vars
485+
* @t: address to timer_list inside tp_vars
486486
*
487487
* If fired it means that there was packet loss.
488488
* Switch to Slow Start, set the ss_threshold to half of the current cwnd and
@@ -1106,7 +1106,7 @@ static void batadv_tp_reset_receiver_timer(struct batadv_tp_vars *tp_vars)
11061106
/**
11071107
* batadv_tp_receiver_shutdown - stop a tp meter receiver when timeout is
11081108
* reached without received ack
1109-
* @arg: address of the related tp_vars
1109+
* @t: address to timer_list inside tp_vars
11101110
*/
11111111
static void batadv_tp_receiver_shutdown(struct timer_list *t)
11121112
{

0 commit comments

Comments
 (0)