17db7d9f3SSven Eckelmann /* SPDX-License-Identifier: GPL-2.0 */ 2ac79cbb9SSven Eckelmann /* Copyright (C) 2007-2017 B.A.T.M.A.N. contributors: 3c6c8fea2SSven Eckelmann * 4c6c8fea2SSven Eckelmann * Marek Lindner, Simon Wunderlich 5c6c8fea2SSven Eckelmann * 6c6c8fea2SSven Eckelmann * This program is free software; you can redistribute it and/or 7c6c8fea2SSven Eckelmann * modify it under the terms of version 2 of the GNU General Public 8c6c8fea2SSven Eckelmann * License as published by the Free Software Foundation. 9c6c8fea2SSven Eckelmann * 10c6c8fea2SSven Eckelmann * This program is distributed in the hope that it will be useful, but 11c6c8fea2SSven Eckelmann * WITHOUT ANY WARRANTY; without even the implied warranty of 12c6c8fea2SSven Eckelmann * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13c6c8fea2SSven Eckelmann * General Public License for more details. 14c6c8fea2SSven Eckelmann * 15c6c8fea2SSven Eckelmann * You should have received a copy of the GNU General Public License 16ebf38fb7SAntonio Quartulli * along with this program; if not, see <http://www.gnu.org/licenses/>. 17c6c8fea2SSven Eckelmann */ 18c6c8fea2SSven Eckelmann 19c6c8fea2SSven Eckelmann #ifndef _NET_BATMAN_ADV_MAIN_H_ 20c6c8fea2SSven Eckelmann #define _NET_BATMAN_ADV_MAIN_H_ 21c6c8fea2SSven Eckelmann 22bc58eeefSMarek Lindner #define BATADV_DRIVER_AUTHOR "Marek Lindner <mareklindner@neomailbox.ch>, " \ 23c679ff8fSSimon Wunderlich "Simon Wunderlich <sw@simonwunderlich.de>" 2442d0b044SSven Eckelmann #define BATADV_DRIVER_DESC "B.A.T.M.A.N. advanced" 2542d0b044SSven Eckelmann #define BATADV_DRIVER_DEVICE "batman-adv" 26c6c8fea2SSven Eckelmann 2742d0b044SSven Eckelmann #ifndef BATADV_SOURCE_VERSION 2802dd9a8aSSimon Wunderlich #define BATADV_SOURCE_VERSION "2018.0" 2944c4349aSSven Eckelmann #endif 30c6c8fea2SSven Eckelmann 31c6c8fea2SSven Eckelmann /* B.A.T.M.A.N. parameters */ 32c6c8fea2SSven Eckelmann 3342d0b044SSven Eckelmann #define BATADV_TQ_MAX_VALUE 255 340da00359SAntonio Quartulli #define BATADV_THROUGHPUT_MAX_VALUE 0xFFFFFFFF 3542d0b044SSven Eckelmann #define BATADV_JITTER 20 36c6c8fea2SSven Eckelmann 376e215fd8SSven Eckelmann /* Time To Live of broadcast messages */ 3842d0b044SSven Eckelmann #define BATADV_TTL 50 396e215fd8SSven Eckelmann 4081f02683SSimon Wunderlich /* maximum sequence number age of broadcast messages */ 4181f02683SSimon Wunderlich #define BATADV_BCAST_MAX_AGE 64 4281f02683SSimon Wunderlich 436e215fd8SSven Eckelmann /* purge originators after time in seconds if no valid packet comes in 4442d0b044SSven Eckelmann * -> TODO: check influence on BATADV_TQ_LOCAL_WINDOW_SIZE 459cfc7bd6SSven Eckelmann */ 4642d0b044SSven Eckelmann #define BATADV_PURGE_TIMEOUT 200000 /* 200 seconds */ 477cf4d520SAntonio Quartulli #define BATADV_TT_LOCAL_TIMEOUT 600000 /* in milliseconds */ 48a51fb9b2SAntonio Quartulli #define BATADV_TT_CLIENT_ROAM_TIMEOUT 600000 /* in milliseconds */ 4930cfd02bSAntonio Quartulli #define BATADV_TT_CLIENT_TEMP_TIMEOUT 600000 /* in milliseconds */ 5072414442SAntonio Quartulli #define BATADV_TT_WORK_PERIOD 5000 /* 5 seconds */ 5172414442SAntonio Quartulli #define BATADV_ORIG_WORK_PERIOD 1000 /* 1 second */ 52cbebd363SLinus Lüssing #define BATADV_MCAST_WORK_PERIOD 500 /* 0.5 seconds */ 532f1dfbe1SAntonio Quartulli #define BATADV_DAT_ENTRY_TIMEOUT (5 * 60000) /* 5 mins in milliseconds */ 54015758d0SAntonio Quartulli /* sliding packet range of received originator messages in sequence numbers 559cfc7bd6SSven Eckelmann * (should be a multiple of our word size) 569cfc7bd6SSven Eckelmann */ 5742d0b044SSven Eckelmann #define BATADV_TQ_LOCAL_WINDOW_SIZE 64 58a51fb9b2SAntonio Quartulli /* milliseconds we have to keep pending tt_req */ 5942d0b044SSven Eckelmann #define BATADV_TT_REQUEST_TIMEOUT 3000 60a73105b8SAntonio Quartulli 6142d0b044SSven Eckelmann #define BATADV_TQ_GLOBAL_WINDOW_SIZE 5 6242d0b044SSven Eckelmann #define BATADV_TQ_LOCAL_BIDRECT_SEND_MINIMUM 1 6342d0b044SSven Eckelmann #define BATADV_TQ_LOCAL_BIDRECT_RECV_MINIMUM 1 6442d0b044SSven Eckelmann #define BATADV_TQ_TOTAL_BIDRECT_LIMIT 1 65c6c8fea2SSven Eckelmann 66162bd64cSLinus Luessing /* B.A.T.M.A.N. V */ 67c833484eSAntonio Quartulli #define BATADV_THROUGHPUT_DEFAULT_VALUE 10 /* 1 Mbps */ 688d2d499eSAntonio Quartulli #define BATADV_ELP_PROBES_PER_NODE 2 698d2d499eSAntonio Quartulli #define BATADV_ELP_MIN_PROBE_SIZE 200 /* bytes */ 708d2d499eSAntonio Quartulli #define BATADV_ELP_PROBE_MAX_TX_DIFF 100 /* milliseconds */ 71162bd64cSLinus Luessing #define BATADV_ELP_MAX_AGE 64 729323158eSAntonio Quartulli #define BATADV_OGM_MAX_ORIGDIFF 5 739323158eSAntonio Quartulli #define BATADV_OGM_MAX_AGE 64 74162bd64cSLinus Luessing 7542d0b044SSven Eckelmann /* number of OGMs sent with the last tt diff */ 7642d0b044SSven Eckelmann #define BATADV_TT_OGM_APPEND_MAX 3 77a73105b8SAntonio Quartulli 789cfc7bd6SSven Eckelmann /* Time in which a client can roam at most ROAMING_MAX_COUNT times in 79a51fb9b2SAntonio Quartulli * milliseconds 809cfc7bd6SSven Eckelmann */ 8142d0b044SSven Eckelmann #define BATADV_ROAMING_MAX_TIME 20000 8242d0b044SSven Eckelmann #define BATADV_ROAMING_MAX_COUNT 5 83cc47f66eSAntonio Quartulli 8442d0b044SSven Eckelmann #define BATADV_NO_FLAGS 0 85ecbd5321SMarek Lindner 8642d0b044SSven Eckelmann #define BATADV_NULL_IFINDEX 0 /* dummy ifindex used to avoid iface checks */ 87bc279080SAntonio Quartulli 889464d071SAntonio Quartulli #define BATADV_NO_MARK 0 899464d071SAntonio Quartulli 9089652331SSimon Wunderlich /* default interface for multi interface operation. The default interface is 9189652331SSimon Wunderlich * used for communication which originated locally (i.e. is not forwarded) 9289652331SSimon Wunderlich * or where special forwarding is not desired/necessary. 9389652331SSimon Wunderlich */ 9489652331SSimon Wunderlich #define BATADV_IF_DEFAULT ((struct batadv_hard_iface *)NULL) 9589652331SSimon Wunderlich 9642d0b044SSven Eckelmann #define BATADV_NUM_WORDS BITS_TO_LONGS(BATADV_TQ_LOCAL_WINDOW_SIZE) 97c6c8fea2SSven Eckelmann 9842d0b044SSven Eckelmann #define BATADV_LOG_BUF_LEN 8192 /* has to be a power of 2 */ 99c6c8fea2SSven Eckelmann 100caf65bfcSMatthias Schiffer /* number of packets to send for broadcasts on different interface types */ 101caf65bfcSMatthias Schiffer #define BATADV_NUM_BCASTS_DEFAULT 1 102caf65bfcSMatthias Schiffer #define BATADV_NUM_BCASTS_WIRELESS 3 103caf65bfcSMatthias Schiffer #define BATADV_NUM_BCASTS_MAX 3 104caf65bfcSMatthias Schiffer 10533a3bb4aSAntonio Quartulli /* length of the single packet used by the TP meter */ 10633a3bb4aSAntonio Quartulli #define BATADV_TP_PACKET_LEN ETH_DATA_LEN 10733a3bb4aSAntonio Quartulli 108c384ea3eSAntonio Quartulli /* msecs after which an ARP_REQUEST is sent in broadcast as fallback */ 109c384ea3eSAntonio Quartulli #define ARP_REQ_DELAY 250 110785ea114SAntonio Quartulli /* numbers of originator to contact for any PUT/GET DHT operation */ 111785ea114SAntonio Quartulli #define BATADV_DAT_CANDIDATES_NUM 3 112785ea114SAntonio Quartulli 113a0e28775SMartin Hundebøll /* BATADV_TQ_SIMILARITY_THRESHOLD - TQ points that a secondary metric can differ 114c43c981eSAntonio Quartulli * at most from the primary one in order to be still considered acceptable 115c43c981eSAntonio Quartulli */ 116c43c981eSAntonio Quartulli #define BATADV_TQ_SIMILARITY_THRESHOLD 50 117c43c981eSAntonio Quartulli 1186e215fd8SSven Eckelmann /* should not be bigger than 512 bytes or change the size of 1199cfc7bd6SSven Eckelmann * forw_packet->direct_link_flags 1209cfc7bd6SSven Eckelmann */ 12142d0b044SSven Eckelmann #define BATADV_MAX_AGGREGATION_BYTES 512 12242d0b044SSven Eckelmann #define BATADV_MAX_AGGREGATION_MS 100 123c6c8fea2SSven Eckelmann 12442d0b044SSven Eckelmann #define BATADV_BLA_PERIOD_LENGTH 10000 /* 10 seconds */ 125e1544f3cSSimon Wunderlich #define BATADV_BLA_BACKBONE_TIMEOUT (BATADV_BLA_PERIOD_LENGTH * 6) 12642d0b044SSven Eckelmann #define BATADV_BLA_CLAIM_TIMEOUT (BATADV_BLA_PERIOD_LENGTH * 10) 12728709878SSimon Wunderlich #define BATADV_BLA_WAIT_PERIODS 3 128cd9c7bfbSSimon Wunderlich #define BATADV_BLA_LOOPDETECT_PERIODS 6 129cd9c7bfbSSimon Wunderlich #define BATADV_BLA_LOOPDETECT_TIMEOUT 3000 /* 3 seconds */ 130fe2da6ffSSimon Wunderlich 13142d0b044SSven Eckelmann #define BATADV_DUPLIST_SIZE 16 13242d0b044SSven Eckelmann #define BATADV_DUPLIST_TIMEOUT 500 /* 500 ms */ 1336e215fd8SSven Eckelmann /* don't reset again within 30 seconds */ 13442d0b044SSven Eckelmann #define BATADV_RESET_PROTECTION_MS 30000 13542d0b044SSven Eckelmann #define BATADV_EXPECTED_SEQNO_RANGE 65536 136c6c8fea2SSven Eckelmann 137d56b1705SMartin Hundebøll #define BATADV_NC_NODE_TIMEOUT 10000 /* Milliseconds */ 138d56b1705SMartin Hundebøll 13933a3bb4aSAntonio Quartulli /** 14033a3bb4aSAntonio Quartulli * BATADV_TP_MAX_NUM - maximum number of simultaneously active tp sessions 14133a3bb4aSAntonio Quartulli */ 14233a3bb4aSAntonio Quartulli #define BATADV_TP_MAX_NUM 5 14333a3bb4aSAntonio Quartulli 14439c75a51SSven Eckelmann enum batadv_mesh_state { 14539c75a51SSven Eckelmann BATADV_MESH_INACTIVE, 14639c75a51SSven Eckelmann BATADV_MESH_ACTIVE, 14739c75a51SSven Eckelmann BATADV_MESH_DEACTIVATING, 148e8958dbfSSven Eckelmann }; 149c6c8fea2SSven Eckelmann 15042d0b044SSven Eckelmann #define BATADV_BCAST_QUEUE_LEN 256 15142d0b044SSven Eckelmann #define BATADV_BATMAN_QUEUE_LEN 256 152c6c8fea2SSven Eckelmann 15339c75a51SSven Eckelmann enum batadv_uev_action { 15439c75a51SSven Eckelmann BATADV_UEV_ADD = 0, 15539c75a51SSven Eckelmann BATADV_UEV_DEL, 15639c75a51SSven Eckelmann BATADV_UEV_CHANGE, 157cd9c7bfbSSimon Wunderlich BATADV_UEV_LOOPDETECT, 158c6bda689SAntonio Quartulli }; 159c6bda689SAntonio Quartulli 16039c75a51SSven Eckelmann enum batadv_uev_type { 16139c75a51SSven Eckelmann BATADV_UEV_GW = 0, 162cd9c7bfbSSimon Wunderlich BATADV_UEV_BLA, 163c6bda689SAntonio Quartulli }; 164c6bda689SAntonio Quartulli 16542d0b044SSven Eckelmann #define BATADV_GW_THRESHOLD 50 16643676ab5SAntonio Quartulli 167610bfc6bSMartin Hundebøll /* Number of fragment chains for each orig_node */ 168610bfc6bSMartin Hundebøll #define BATADV_FRAG_BUFFER_COUNT 8 169610bfc6bSMartin Hundebøll /* Maximum number of fragments for one packet */ 170610bfc6bSMartin Hundebøll #define BATADV_FRAG_MAX_FRAGMENTS 16 171610bfc6bSMartin Hundebøll /* Maxumim size of each fragment */ 1728ea026b1SMatthias Schiffer #define BATADV_FRAG_MAX_FRAG_SIZE 1280 173610bfc6bSMartin Hundebøll /* Time to keep fragments while waiting for rest of the fragments */ 174610bfc6bSMartin Hundebøll #define BATADV_FRAG_TIMEOUT 10000 175610bfc6bSMartin Hundebøll 176785ea114SAntonio Quartulli #define BATADV_DAT_CANDIDATE_NOT_FOUND 0 177785ea114SAntonio Quartulli #define BATADV_DAT_CANDIDATE_ORIG 1 178785ea114SAntonio Quartulli 17921a1236bSSven Eckelmann /* Debug Messages */ 180c6c8fea2SSven Eckelmann #ifdef pr_fmt 181c6c8fea2SSven Eckelmann #undef pr_fmt 182c6c8fea2SSven Eckelmann #endif 1836e215fd8SSven Eckelmann /* Append 'batman-adv: ' before kernel messages */ 1846e215fd8SSven Eckelmann #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt 185c6c8fea2SSven Eckelmann 18621a1236bSSven Eckelmann /* Kernel headers */ 187c6c8fea2SSven Eckelmann 1881e2c2a4fSSven Eckelmann #include <linux/bitops.h> /* for packet.h */ 1891e2c2a4fSSven Eckelmann #include <linux/compiler.h> 1901e2c2a4fSSven Eckelmann #include <linux/etherdevice.h> 1911e2c2a4fSSven Eckelmann #include <linux/if_ether.h> /* for packet.h */ 192fcafa5e7SSven Eckelmann #include <linux/if_vlan.h> 193fcafa5e7SSven Eckelmann #include <linux/jiffies.h> 194fcafa5e7SSven Eckelmann #include <linux/percpu.h> 1951e2c2a4fSSven Eckelmann #include <linux/types.h> 19616052789SAntonio Quartulli 197f7a2bd65SSven Eckelmann #include "packet.h" 198c6c8fea2SSven Eckelmann #include "types.h" 199c6c8fea2SSven Eckelmann 200ba412080SSven Eckelmann struct net_device; 201ba412080SSven Eckelmann struct packet_type; 2021e2c2a4fSSven Eckelmann struct seq_file; 2031e2c2a4fSSven Eckelmann struct sk_buff; 2041e2c2a4fSSven Eckelmann 205f7a2bd65SSven Eckelmann /** 206*7e9a8c2cSSven Eckelmann * batadv_print_vid() - return printable version of vid information 207f7a2bd65SSven Eckelmann * @vid: the VLAN identifier 208f7a2bd65SSven Eckelmann * 209f7a2bd65SSven Eckelmann * Return: -1 when no VLAN is used, VLAN id otherwise 210f7a2bd65SSven Eckelmann */ 211f7a2bd65SSven Eckelmann static inline int batadv_print_vid(unsigned short vid) 212f7a2bd65SSven Eckelmann { 213f7a2bd65SSven Eckelmann if (vid & BATADV_VLAN_HAS_TAG) 214f7a2bd65SSven Eckelmann return (int)(vid & VLAN_VID_MASK); 215f7a2bd65SSven Eckelmann else 216f7a2bd65SSven Eckelmann return -1; 217f7a2bd65SSven Eckelmann } 218eb2deb6bSAntonio Quartulli 2193193e8fdSSven Eckelmann extern struct list_head batadv_hardif_list; 220c6c8fea2SSven Eckelmann 2213193e8fdSSven Eckelmann extern unsigned char batadv_broadcast_addr[]; 2223193e8fdSSven Eckelmann extern struct workqueue_struct *batadv_event_workqueue; 223c6c8fea2SSven Eckelmann 2243193e8fdSSven Eckelmann int batadv_mesh_init(struct net_device *soft_iface); 2253193e8fdSSven Eckelmann void batadv_mesh_free(struct net_device *soft_iface); 2266b5e971aSSven Eckelmann bool batadv_is_my_mac(struct batadv_priv *bat_priv, const u8 *addr); 22730da63a6SMarek Lindner struct batadv_hard_iface * 22830da63a6SMarek Lindner batadv_seq_print_text_primary_if_get(struct seq_file *seq); 229411d6ed9SMarek Lindner int batadv_max_header_len(void); 230c54f38c9SSimon Wunderlich void batadv_skb_set_priority(struct sk_buff *skb, int offset); 2313193e8fdSSven Eckelmann int batadv_batman_skb_recv(struct sk_buff *skb, struct net_device *dev, 2323193e8fdSSven Eckelmann struct packet_type *ptype, 2333193e8fdSSven Eckelmann struct net_device *orig_dev); 23456303d34SSven Eckelmann int 2356b5e971aSSven Eckelmann batadv_recv_handler_register(u8 packet_type, 236ffa995e0SMarek Lindner int (*recv_handler)(struct sk_buff *, 23756303d34SSven Eckelmann struct batadv_hard_iface *)); 2386b5e971aSSven Eckelmann void batadv_recv_handler_unregister(u8 packet_type); 23995a066d8SSven Eckelmann __be32 batadv_skb_crc32(struct sk_buff *skb, u8 *payload_ptr); 240c6c8fea2SSven Eckelmann 2410aca86cdSAntonio Quartulli /** 242*7e9a8c2cSSven Eckelmann * batadv_compare_eth() - Compare two not u16 aligned Ethernet addresses 2437afcbbefSSven Eckelmann * @data1: Pointer to a six-byte array containing the Ethernet address 2447afcbbefSSven Eckelmann * @data2: Pointer other six-byte array containing the Ethernet address 24539901e71SMarek Lindner * 246c3923b7aSJoe Perches * note: can't use ether_addr_equal() as it requires aligned memory 24762fe710fSSven Eckelmann * 2484b426b10SSven Eckelmann * Return: true if they are the same ethernet addr 24939901e71SMarek Lindner */ 250f2d5cf2aSMarkus Pargmann static inline bool batadv_compare_eth(const void *data1, const void *data2) 25139901e71SMarek Lindner { 252d9cd4fe5SJoe Perches return ether_addr_equal_unaligned(data1, data2); 25339901e71SMarek Lindner } 25439901e71SMarek Lindner 2552c53040fSBen Hutchings /** 256*7e9a8c2cSSven Eckelmann * batadv_has_timed_out() - compares current time (jiffies) and timestamp + 2576d030de8SAntonio Quartulli * timeout 258a04ccd59SMartin Hundebøll * @timestamp: base value to compare with (in jiffies) 259a04ccd59SMartin Hundebøll * @timeout: added to base value before comparing (in milliseconds) 260a04ccd59SMartin Hundebøll * 26162fe710fSSven Eckelmann * Return: true if current time is after timestamp + timeout 262a04ccd59SMartin Hundebøll */ 2631eda58bfSSven Eckelmann static inline bool batadv_has_timed_out(unsigned long timestamp, 2641eda58bfSSven Eckelmann unsigned int timeout) 265a04ccd59SMartin Hundebøll { 266a04ccd59SMartin Hundebøll return time_is_before_jiffies(timestamp + msecs_to_jiffies(timeout)); 267a04ccd59SMartin Hundebøll } 268747e4221SSven Eckelmann 2693e34819eSSven Eckelmann #define batadv_atomic_dec_not_zero(v) atomic_add_unless((v), -1, 0) 2705f657ec0SAntonio Quartulli 271f5d33d37SAntonio Quartulli /* Returns the smallest signed integer in two's complement with the sizeof x */ 2723e34819eSSven Eckelmann #define batadv_smallest_signed_int(x) (1u << (7u + 8u * (sizeof(x) - 1u))) 273f5d33d37SAntonio Quartulli 274f5d33d37SAntonio Quartulli /* Checks if a sequence number x is a predecessor/successor of y. 275f5d33d37SAntonio Quartulli * they handle overflows/underflows and can correctly check for a 276f5d33d37SAntonio Quartulli * predecessor/successor unless the variable sequence number has grown by 277f5d33d37SAntonio Quartulli * more then 2**(bitwidth(x)-1)-1. 2786b5e971aSSven Eckelmann * This means that for a u8 with the maximum value 255, it would think: 279f5d33d37SAntonio Quartulli * - when adding nothing - it is neither a predecessor nor a successor 280f5d33d37SAntonio Quartulli * - before adding more than 127 to the starting value - it is a predecessor, 281f5d33d37SAntonio Quartulli * - when adding 128 - it is neither a predecessor nor a successor, 2829cfc7bd6SSven Eckelmann * - after adding more than 127 to the starting value - it is a successor 2839cfc7bd6SSven Eckelmann */ 2843e34819eSSven Eckelmann #define batadv_seq_before(x, y) ({typeof(x)_d1 = (x); \ 2850bb85751SSven Eckelmann typeof(y)_d2 = (y); \ 2860bb85751SSven Eckelmann typeof(x)_dummy = (_d1 - _d2); \ 2870bb85751SSven Eckelmann (void)(&_d1 == &_d2); \ 2883e34819eSSven Eckelmann _dummy > batadv_smallest_signed_int(_dummy); }) 2893e34819eSSven Eckelmann #define batadv_seq_after(x, y) batadv_seq_before(y, x) 290f5d33d37SAntonio Quartulli 291f8214865SMartin Hundebøll /* Stop preemption on local cpu while incrementing the counter */ 29256303d34SSven Eckelmann static inline void batadv_add_counter(struct batadv_priv *bat_priv, size_t idx, 293f8214865SMartin Hundebøll size_t count) 294f8214865SMartin Hundebøll { 29556917443SShan Wei this_cpu_add(bat_priv->bat_counters[idx], count); 296f8214865SMartin Hundebøll } 297f8214865SMartin Hundebøll 298f8214865SMartin Hundebøll #define batadv_inc_counter(b, i) batadv_add_counter(b, i, 1) 299f8214865SMartin Hundebøll 3003c12de9aSMartin Hundebøll /* Define a macro to reach the control buffer of the skb. The members of the 3013c12de9aSMartin Hundebøll * control buffer are defined in struct batadv_skb_cb in types.h. 3023c12de9aSMartin Hundebøll * The macro is inspired by the similar macro TCP_SKB_CB() in tcp.h. 3033c12de9aSMartin Hundebøll */ 3043c12de9aSMartin Hundebøll #define BATADV_SKB_CB(__skb) ((struct batadv_skb_cb *)&((__skb)->cb[0])) 3053c12de9aSMartin Hundebøll 306c018ad3dSAntonio Quartulli unsigned short batadv_get_vid(struct sk_buff *skb, size_t header_len); 307eceb22aeSAntonio Quartulli bool batadv_vlan_ap_isola_get(struct batadv_priv *bat_priv, unsigned short vid); 308ef261577SMarek Lindner 309c6c8fea2SSven Eckelmann #endif /* _NET_BATMAN_ADV_MAIN_H_ */ 310