Commit aa27c312 authored by Marek Lindner's avatar Marek Lindner Committed by Antonio Quartulli

batman-adv: do not print orig nodes without nc neighbors on nc table print

Signed-off-by: default avatarMarek Lindner <lindner_marek@yahoo.de>
Signed-off-by: default avatarAntonio Quartulli <ordex@autistici.org>
parent e54c77f0
...@@ -1763,6 +1763,13 @@ int batadv_nc_nodes_seq_print_text(struct seq_file *seq, void *offset) ...@@ -1763,6 +1763,13 @@ int batadv_nc_nodes_seq_print_text(struct seq_file *seq, void *offset)
/* For each orig_node in this bin */ /* For each orig_node in this bin */
rcu_read_lock(); rcu_read_lock();
hlist_for_each_entry_rcu(orig_node, head, hash_entry) { hlist_for_each_entry_rcu(orig_node, head, hash_entry) {
/* no need to print the orig node if it does not have
* network coding neighbors
*/
if (list_empty(&orig_node->in_coding_list) &&
list_empty(&orig_node->out_coding_list))
continue;
seq_printf(seq, "Node: %pM\n", orig_node->orig); seq_printf(seq, "Node: %pM\n", orig_node->orig);
seq_puts(seq, " Ingoing: "); seq_puts(seq, " Ingoing: ");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment