Donald Sharp
28328ea953
bgpd: Convert to using ETH_ALEN
...
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-08-04 09:06:14 -04:00
Lou Berger
e7038ddec6
bgpd rfapi: use afi_t
...
Signed-off-by: Lou Berger <lberger@labn.net>
2017-07-27 13:15:53 -04:00
Lou Berger
0ae6124f48
bgp rfapi: use route_table_init and _finish (fixes crash due to recent lib change)
...
Signed-off-by: Lou Berger <lberger@labn.net>
2017-07-27 11:02:31 -04:00
David Lamparter
9d303b37d7
Revert "*: reindent pt. 2"
...
This reverts commit c14777c6bf
.
clang 5 is not widely available enough for people to indent with. This
is particularly problematic when rebasing/adjusting branches.
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-22 14:52:33 +02:00
whitespace / reindent
c14777c6bf
*: reindent pt. 2
...
w/ clang 5
* reflow comments
* struct members go 1 per line
* binpack algo was adjusted
2017-07-17 15:26:02 -04:00
whitespace / reindent
d62a17aede
*: reindent
...
indent.py `git ls-files | pcregrep '\.[ch]$' | pcregrep -v '^(ldpd|babeld|nhrpd)/'`
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-17 14:04:07 +02:00
Donald Sharp
1ea6b3f237
Merge remote-tracking branch 'origin/master' into evpn_plus_struct_attr
2017-07-14 08:24:46 -04:00
Donald Sharp
da571b7a6c
Merge remote-tracking branch 'origin/master' into evpn_plus_struct_attr
2017-07-14 08:11:05 -04:00
David Lamparter
2d8270596a
Merge remote-tracking branch 'frr/master' into newline-redux
...
Lots of conflicts from CMD_WARNING_CONFIG_FAILED...
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-14 13:07:30 +02:00
David Lamparter
cdda201036
*: remove VTYNL, part 5 of 6
...
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-14 10:20:03 +02:00
David Lamparter
61b7d449bd
*: remove VTYNL, part 3 of 6
...
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-14 10:20:03 +02:00
David Lamparter
181039f3d7
*: ditch vty_outln(), part 2 of 2
...
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-14 10:19:58 +02:00
Daniel Walton
f1a05de982
vtysh: return non-zero for configuration failures
...
Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
This allows frr-reload.py (or anything else that scripts via vtysh)
to know if the vtysh command worked or hit an error.
2017-07-13 19:56:08 +00:00
David Lamparter
5c7571d43f
*: ditch vty_outln(), part 1 of 2
...
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-13 20:29:22 +02:00
Donald Sharp
aadc090505
bgpd: Refactor 'struct attr_extra' into 'struct attr'
...
Most of the attributes in 'struct attr_extra' allow for
the more interesting cases of using bgp. The extra
overhead of managing it will induce errors as we add
more attributes and the extra memory overhead is
negligible on anything but full bgp feeds.
Additionally this greatly simplifies the code for
the handling of data.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
bgpd: Fix missing label set
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-07-12 15:23:18 -04:00
Daniel Walton
1161690b93
Merge branch 'master' of https://github.com/dwalton76/frr into bgpd-ipv4-plus-label-misc3
...
Conflicts:
bgpd/bgp_route.c
2017-06-30 17:52:56 +00:00
Quentin Young
1318e7c841
*: s/VTY_NEWLINE/VTYNL/g
...
Should be able to fit more vty_out onto one line now
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-06-29 17:34:54 +00:00
Quentin Young
96ade3ed77
*: use vty_outln
...
Saves 400 lines
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-06-29 17:31:28 +00:00
Russ White
0bc44f61c9
Merge pull request #754 from qlyoung/fix-argv-arg
...
use argv->text where appropriate
2017-06-29 11:06:15 -04:00
Quentin Young
facfee22f5
*: remove VTY_GET_*
...
CLI validates input tokens, so there's no need to do it in handler
functions anymore.
spatch follows
----------------
@getull@
expression v;
expression str;
@@
<...
- VTY_GET_ULL(..., v, str)
+ v = strtoull (str, NULL, 10)
...>
@getul@
expression v;
expression str;
@@
<...
- VTY_GET_ULONG(..., v, str)
+ v = strtoul (str, NULL, 10)
...>
@getintrange@
expression name;
expression v;
expression str;
@@
<...
- VTY_GET_INTEGER_RANGE(name, v, str, ...)
+ v = strtoul (str, NULL, 10)
...>
@getint@
expression v;
expression str;
@@
<...
- VTY_GET_INTEGER(..., v, str)
+ v = strtoul (str, NULL, 10)
...>
@getv4@
expression v;
expression str;
@@
<...
- VTY_GET_IPV4_ADDRESS(..., v, str)
+ inet_aton (str, &v)
...>
@getv4pfx@
expression v;
expression str;
@@
<...
- VTY_GET_IPV4_PREFIX(..., v, str)
+ str2prefix_ipv4 (str, &v)
...>
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-06-27 19:04:41 +00:00
Quentin Young
7e045c3d42
*: use ->text and strmatch where appropriate
...
Still need to go fix all the places where we do a 1-char strncmp...
spatch follows
------------------
@asdf@
expression idx;
@@
<...
strcmp (
- argv[idx]->arg,
+ argv[idx]->text,
...)
...>
@depends on asdf@
expression idx;
@@
<...
- !strcmp (argv[idx]->text,
+ strmatch (argv[idx]->text,
...)
...>
@depends on asdf@
expression idx;
expression arg;
@@
<...
- strcmp (argv[idx]->text, arg) == 0
+ strmatch (argv[idx]->text, arg)
...>
@depends on asdf@
expression idx;
expression arg;
@@
<...
- strcmp (argv[idx]->text, arg) != 0
+ !strmatch (argv[idx]->text, arg)
...>
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2017-06-27 17:46:42 +00:00
Daniel Walton
0826e83cf6
bgpd: Install SAFI_LABELED_UNICAST routes in SAFI_UNICAST table
...
Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
2017-06-20 14:50:00 +00:00
David Lamparter
896014f4bc
*: make consistent & update GPLv2 file headers
...
The FSF's address changed, and we had a mixture of comment styles for
the GPL file header. (The style with * at the beginning won out with
580 to 141 in existing files.)
Note: I've intentionally left intact other "variations" of the copyright
header, e.g. whether it says "Zebra", "Quagga", "FRR", or nothing.
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-05-15 16:37:41 +02:00
Lou Berger
e5efc58be9
bgpd: fix rfapi label origination (Issue #473 )
...
Signed-off-by: Lou Berger <lberger@labn.net>
2017-05-13 17:46:05 -04:00
Philippe Guibert
f47195ae58
bgpd: revert some RT ecom filtering to fix valgrind id'ed error and
...
potential misreporting.
This commits revert the call of ecommunity_ecom2str without filtering.
Signed-off-by: Lou Berger <lberger@labn.net>
2017-02-17 08:57:37 +01:00
Philippe Guibert
0aa9c36c07
bgpd: replace AFI_ETHER reference with AFI_L2VPN ref
...
The introduction of AFI_L2VPN prefix makes usage of AFI_ETHER deprecated
and is of no usage currently. The former replaces the latter one.
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2017-02-14 13:59:00 +01:00
Philippe Guibert
72831436ed
bgpd: fix rfapi call to ecom2str with correct number of parameters
...
This commit is a complement for bgpd: handling router mac extended
community. As API of bgp_ecommunity ecom2str() function changed, rfapi
file has diverged with this API. The commit adds the correct number of
parameters.
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2017-02-14 13:58:59 +01:00
Philippe Guibert
e82202b7a1
bgpd: support for router mac extended community
...
As per draft-ietf-bess-evpn-inter-subnet-forwarding-01, chapter 6.1,
a new extended community called router's MAC Extended Community is
provided. This community is appended to extended community list.
Note that a show API has been changed in order to be able to not
display (or not) this new type.
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2017-02-14 13:58:58 +01:00
Donald Sharp
b384af46d5
Merge pull request #135 from LabNConsulting/working/master/patch-set/misc+vrf
...
Master: misc vnc/rfapi and VRF
2017-02-02 09:25:24 -05:00
G. Paul Ziemba
2125ebfa6d
bgpd rfapi: small debug log enhancements
...
Signed-off-by: G. Paul Ziemba <paulz@labn.net>
2017-02-01 22:18:40 -05:00
Lou Berger
130c31c835
bgpd rfapi: only auto add default tunnel type for local registrations
...
Signed-off-by: Lou Berger <lberger@labn.net>
2017-01-30 21:14:48 -05:00
Donald Sharp
1dc84b65df
Merge remote-tracking branch 'origin/pr/113' into pr/111
2017-01-27 12:39:06 -05:00
Donald Sharp
c016b6c796
Merge remote-tracking branch 'origin/master' into pr/111
2017-01-27 11:44:42 -05:00
Lou Berger
1c404af8b5
Merge branch 'master' into working/master/patch-set/4-misc-fixes
...
Merged pull request with master
Conflicts:
bgpd/bgp_mplsvpn.c
bgpd/bgp_route.c
bgpd/rfapi/rfapi_vty.c
2017-01-26 09:59:03 -05:00
G. Paul Ziemba
28070ee3c4
bgpd rfapi: Shift rfapi receive hooks for vpn and encap safis into
...
bgp_update/bgp_withdraw (Issue #91 )
Signed-off-by: G. Paul Ziemba <paulz@labn.net>
2017-01-24 13:42:43 -05:00
Lou Berger
8074b6fda3
bgpd rfapi: fix issue where advertised prefixes were not being disambiguated
...
by RD
Signed-off-by: Lou Berger <lberger@labn.net>
2017-01-24 13:40:12 -05:00
Lou Berger
5ff06872e9
bgpd: add vrf-policy config using existing vnc code
...
add add/clear vrf prefix
+ Modified for FRR master parser
Signed-off-by: Lou Berger <lberger@labn.net>
2017-01-22 20:54:57 -05:00
Lou Berger
cedb5a7124
bgpd rfapi: fix issue where advertised prefixes were not being disambiguated
...
by RD
Signed-off-by: Lou Berger <lberger@labn.net>
2017-01-22 20:54:39 -05:00
Lou Berger
3eebadeb62
bgpd rfapi: use VN as nexthop for MPLS tunnels too
...
Also minor show format cleanup
Signed-off-by: Lou Berger <lberger@labn.net>
2017-01-18 18:26:52 -05:00
Donald Sharp
034d2de2e6
bgpd: Fixup some vnc cli
...
Fixup the vnc cli to use the new syntax as well as fixup a bunch
of cli help strings that were wrong.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-01-09 10:25:16 -05:00
Donald Sharp
3b14d86eed
Merge remote-tracking branch 'origin/stable/2.0'
2017-01-06 09:58:21 -05:00
Lou Berger
7979998755
rfapi: pickup recent changes
...
expose bgp_rfapi_get_group_by_lni_label for use by rfp
add EVPN Ethernet Tag (VID) RT
ensure as is init'ed
fix spelling of information
Signed-off-by: Lou Berger <lberger@labn.net>
2017-01-02 15:04:47 -05:00
David Lamparter
d5bd3e0a6f
Merge branch 'stable/2.0'
...
Conflicts:
bgpd/rfapi/bgp_rfapi_cfg.c
bgpd/rfapi/vnc_debug.c
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2016-12-08 13:21:21 +01:00
Lou Berger
a3b55c2500
bgpd vnc: Add 'debug bgp vnc verbose' target
...
all vnc debug logging is now covered by a 'debug bgp vnc' target
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2016-12-08 12:51:26 +01:00
David Lamparter
aed3273f38
bgpd/rfpapi: update for new CLI
...
May contain bugs/mistakes.
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2016-11-29 14:15:05 +01:00
Donald Sharp
d8e012a89e
bgpd: Fix peer->weight usage
...
When setting the weight make sure to use the
correct afi safi to get what we need.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Reviewed-by: Lou Berger <lberger@labn.net>
2016-10-11 08:30:14 -04:00
Lou Berger
31107a358a
rfapi: cleanup some warnings
2016-10-11 07:46:04 -04:00
David Lamparter
608ef8c72d
bgpd/rfp: fix remaining index_sub uses
...
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2016-10-11 13:37:26 +02:00
Daniel Walton
2de1475ffe
some rfapi compile fixes
...
Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
2016-10-05 20:54:55 +00:00
Lou Berger
f8b6f49912
vnc: use directories in includes (request from Martin W.)
2016-10-03 08:17:13 -04:00