Release 4.11 net/batman-adv/bridge_loop_avoidance.h
/* Copyright (C) 2011-2017 B.A.T.M.A.N. contributors:
*
* Simon Wunderlich
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
#ifndef _NET_BATMAN_ADV_BLA_H_
#define _NET_BATMAN_ADV_BLA_H_
#include "main.h"
#include <linux/compiler.h>
#include <linux/stddef.h>
#include <linux/types.h>
struct net_device;
struct netlink_callback;
struct seq_file;
struct sk_buff;
/**
* batadv_bla_is_loopdetect_mac - check if the mac address is from a loop detect
* frame sent by bridge loop avoidance
* @mac: mac address to check
*
* Return: true if the it looks like a loop detect frame
* (mac starts with BA:BE), false otherwise
*/
static inline bool batadv_bla_is_loopdetect_mac(const uint8_t *mac)
{
if (mac[0] == 0xba && mac[1] == 0xbe)
return true;
return false;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 34 | 100.00% | 1 | 100.00% |
Total | 34 | 100.00% | 1 | 100.00% |
#ifdef CONFIG_BATMAN_ADV_BLA
bool batadv_bla_rx(struct batadv_priv *bat_priv, struct sk_buff *skb,
unsigned short vid, bool is_bcast);
bool batadv_bla_tx(struct batadv_priv *bat_priv, struct sk_buff *skb,
unsigned short vid);
bool batadv_bla_is_backbone_gw(struct sk_buff *skb,
struct batadv_orig_node *orig_node,
int hdr_size);
int batadv_bla_claim_table_seq_print_text(struct seq_file *seq, void *offset);
int batadv_bla_claim_dump(struct sk_buff *msg, struct netlink_callback *cb);
int batadv_bla_backbone_table_seq_print_text(struct seq_file *seq,
void *offset);
int batadv_bla_backbone_dump(struct sk_buff *msg, struct netlink_callback *cb);
bool batadv_bla_is_backbone_gw_orig(struct batadv_priv *bat_priv, u8 *orig,
unsigned short vid);
bool batadv_bla_check_bcast_duplist(struct batadv_priv *bat_priv,
struct sk_buff *skb);
void batadv_bla_update_orig_address(struct batadv_priv *bat_priv,
struct batadv_hard_iface *primary_if,
struct batadv_hard_iface *oldif);
void batadv_bla_status_update(struct net_device *net_dev);
int batadv_bla_init(struct batadv_priv *bat_priv);
void batadv_bla_free(struct batadv_priv *bat_priv);
int batadv_bla_claim_dump(struct sk_buff *msg, struct netlink_callback *cb);
#define BATADV_BLA_CRC_INIT 0
#else /* ifdef CONFIG_BATMAN_ADV_BLA */
static inline bool batadv_bla_rx(struct batadv_priv *bat_priv,
struct sk_buff *skb, unsigned short vid,
bool is_bcast)
{
return false;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 22 | 81.48% | 2 | 33.33% |
Sven Eckelmann | 4 | 14.81% | 3 | 50.00% |
Antonio Quartulli | 1 | 3.70% | 1 | 16.67% |
Total | 27 | 100.00% | 6 | 100.00% |
static inline bool batadv_bla_tx(struct batadv_priv *bat_priv,
struct sk_buff *skb, unsigned short vid)
{
return false;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 19 | 79.17% | 1 | 20.00% |
Sven Eckelmann | 4 | 16.67% | 3 | 60.00% |
Antonio Quartulli | 1 | 4.17% | 1 | 20.00% |
Total | 24 | 100.00% | 5 | 100.00% |
static inline bool batadv_bla_is_backbone_gw(struct sk_buff *skb,
struct batadv_orig_node *orig_node,
int hdr_size)
{
return false;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 19 | 82.61% | 1 | 25.00% |
Sven Eckelmann | 4 | 17.39% | 3 | 75.00% |
Total | 23 | 100.00% | 4 | 100.00% |
static inline int batadv_bla_claim_table_seq_print_text(struct seq_file *seq,
void *offset)
{
return 0;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 18 | 94.74% | 2 | 66.67% |
Sven Eckelmann | 1 | 5.26% | 1 | 33.33% |
Total | 19 | 100.00% | 3 | 100.00% |
static inline int batadv_bla_backbone_table_seq_print_text(struct seq_file *seq,
void *offset)
{
return 0;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 19 | 100.00% | 2 | 100.00% |
Total | 19 | 100.00% | 2 | 100.00% |
static inline bool batadv_bla_is_backbone_gw_orig(struct batadv_priv *bat_priv,
u8 *orig, unsigned short vid)
{
return false;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 14 | 60.87% | 1 | 20.00% |
Antonio Quartulli | 6 | 26.09% | 1 | 20.00% |
Sven Eckelmann | 3 | 13.04% | 3 | 60.00% |
Total | 23 | 100.00% | 5 | 100.00% |
static inline bool
batadv_bla_check_bcast_duplist(struct batadv_priv *bat_priv,
struct sk_buff *skb)
{
return false;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 16 | 80.00% | 2 | 40.00% |
Sven Eckelmann | 4 | 20.00% | 3 | 60.00% |
Total | 20 | 100.00% | 5 | 100.00% |
static inline void
batadv_bla_update_orig_address(struct batadv_priv *bat_priv,
struct batadv_hard_iface *primary_if,
struct batadv_hard_iface *oldif)
{
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 17 | 80.95% | 1 | 33.33% |
Sven Eckelmann | 4 | 19.05% | 2 | 66.67% |
Total | 21 | 100.00% | 3 | 100.00% |
static inline int batadv_bla_init(struct batadv_priv *bat_priv)
{
return 1;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 13 | 86.67% | 1 | 33.33% |
Sven Eckelmann | 2 | 13.33% | 2 | 66.67% |
Total | 15 | 100.00% | 3 | 100.00% |
static inline void batadv_bla_free(struct batadv_priv *bat_priv)
{
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 9 | 81.82% | 1 | 33.33% |
Sven Eckelmann | 2 | 18.18% | 2 | 66.67% |
Total | 11 | 100.00% | 3 | 100.00% |
static inline int batadv_bla_claim_dump(struct sk_buff *msg,
struct netlink_callback *cb)
{
return -EOPNOTSUPP;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Andrew Lunn | 21 | 100.00% | 1 | 100.00% |
Total | 21 | 100.00% | 1 | 100.00% |
static inline int batadv_bla_backbone_dump(struct sk_buff *msg,
struct netlink_callback *cb)
{
return -EOPNOTSUPP;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 21 | 100.00% | 1 | 100.00% |
Total | 21 | 100.00% | 1 | 100.00% |
#endif /* ifdef CONFIG_BATMAN_ADV_BLA */
#endif /* ifndef _NET_BATMAN_ADV_BLA_H_ */
Overall Contributors
Person | Tokens | Prop | Commits | CommitProp |
Simon Wunderlich | 394 | 74.76% | 11 | 52.38% |
Sven Eckelmann | 66 | 12.52% | 7 | 33.33% |
Andrew Lunn | 52 | 9.87% | 1 | 4.76% |
Antonio Quartulli | 15 | 2.85% | 2 | 9.52% |
Total | 527 | 100.00% | 21 | 100.00% |
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.