]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - net/batman-adv/types.h
batman-adv: add bat_neigh_is_equiv_or_better API function
[karo-tx-linux.git] / net / batman-adv / types.h
index 7a00932a55bd305c41adc95adb58ec64eb910ef0..d0e64d269da40667f8cca11631dc0bf1cca5fba6 100644 (file)
@@ -993,6 +993,8 @@ struct batadv_forw_packet {
  * @bat_ogm_schedule: prepare a new outgoing OGM for the send queue
  * @bat_ogm_emit: send scheduled OGM
  * @bat_neigh_cmp: compare the metrics of two neighbors
+ * @bat_neigh_is_equiv_or_better: check if neigh1 is equally good or
+ *  better than neigh2 from the metric prospective
  * @bat_orig_print: print the originator table (optional)
  */
 struct batadv_algo_ops {
@@ -1006,6 +1008,8 @@ struct batadv_algo_ops {
        void (*bat_ogm_emit)(struct batadv_forw_packet *forw_packet);
        int (*bat_neigh_cmp)(struct batadv_neigh_node *neigh1,
                             struct batadv_neigh_node *neigh2);
+       bool (*bat_neigh_is_equiv_or_better)(struct batadv_neigh_node *neigh1,
+                                            struct batadv_neigh_node *neigh2);
        /* orig_node handling API */
        void (*bat_orig_print)(struct batadv_priv *priv, struct seq_file *seq);
 };