summaryrefslogtreecommitdiffstats
path: root/bgpd/bgp_pbr.h
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2018-11-29 15:04:52 +0100
committerPhilippe Guibert <philippe.guibert@6wind.com>2019-01-29 14:15:09 +0100
commit5fa779c9688fa01be8f5f8702de600afc1ba931a (patch)
treec95766f5a2930aad9b499ad99cfcd9accf7261eb /bgpd/bgp_pbr.h
parentbgpd: remove useless fields in bgp_pbr_entry_main (diff)
downloadfrr-5fa779c9688fa01be8f5f8702de600afc1ba931a.tar.xz
frr-5fa779c9688fa01be8f5f8702de600afc1ba931a.zip
bgpd: upon bgp fs study, determine if iprule can be used
instead of using ipset based mechanism to forward packets, there are cases where it is possible to use ip rule based mechanisms (without ipset). Here, this applies to simple fs rules with only 'from any' or 'to any'. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'bgpd/bgp_pbr.h')
-rw-r--r--bgpd/bgp_pbr.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/bgpd/bgp_pbr.h b/bgpd/bgp_pbr.h
index f59aeea8b..eebfdf371 100644
--- a/bgpd/bgp_pbr.h
+++ b/bgpd/bgp_pbr.h
@@ -87,6 +87,9 @@ struct bgp_pbr_entry_action {
/* BGP Policy Route structure */
struct bgp_pbr_entry_main {
+#define BGP_PBR_UNDEFINED 0
+#define BGP_PBR_IPSET 1
+#define BGP_PBR_IPRULE 2
uint8_t type;
/*
@@ -98,6 +101,7 @@ struct bgp_pbr_entry_main {
#define PREFIX_SRC_PRESENT (1 << 0)
#define PREFIX_DST_PRESENT (1 << 1)
+ uint8_t match_bitmask_iprule;
uint8_t match_bitmask;
uint8_t match_src_port_num;