1 /* SPDX-License-Identifier: LGPL-2.1-or-later */
5 Copyright © 2014 Intel Corporation. All rights reserved.
9 #include <linux/neighbour.h>
11 #include "conf-parser.h"
12 #include "ether-addr-util.h"
13 #include "in-addr-util.h"
15 typedef struct Link Link
;
16 typedef struct Network Network
;
18 typedef enum NeighborCacheEntryFlags
{
19 NEIGHBOR_CACHE_ENTRY_FLAGS_USE
= NTF_USE
,
20 NEIGHBOR_CACHE_ENTRY_FLAGS_SELF
= NTF_SELF
,
21 NEIGHBOR_CACHE_ENTRY_FLAGS_MASTER
= NTF_MASTER
,
22 NEIGHBOR_CACHE_ENTRY_FLAGS_ROUTER
= NTF_ROUTER
,
23 _NEIGHBOR_CACHE_ENTRY_FLAGS_MAX
,
24 _NEIGHBOR_CACHE_ENTRY_FLAGS_INVALID
= -EINVAL
,
25 } NeighborCacheEntryFlags
;
27 typedef struct BridgeFDB
{
29 ConfigSection
*section
;
36 struct ether_addr mac_addr
;
37 union in_addr_union destination_addr
;
38 NeighborCacheEntryFlags ntf_flags
;
39 char *outgoing_ifname
;
43 BridgeFDB
*bridge_fdb_free(BridgeFDB
*fdb
);
45 void network_drop_invalid_bridge_fdb_entries(Network
*network
);
47 int link_request_static_bridge_fdb(Link
*link
);
49 CONFIG_PARSER_PROTOTYPE(config_parse_fdb_hwaddr
);
50 CONFIG_PARSER_PROTOTYPE(config_parse_fdb_vlan_id
);
51 CONFIG_PARSER_PROTOTYPE(config_parse_fdb_destination
);
52 CONFIG_PARSER_PROTOTYPE(config_parse_fdb_vxlan_vni
);
53 CONFIG_PARSER_PROTOTYPE(config_parse_fdb_ntf_flags
);
54 CONFIG_PARSER_PROTOTYPE(config_parse_fdb_interface
);