]> git.proxmox.com Git - mirror_frr.git/log
mirror_frr.git
8 years agoredhat: Fix runtime dependency and quaggavty group
Donald Sharp [Tue, 14 Jun 2016 19:06:37 +0000 (15:06 -0400)]
redhat: Fix runtime dependency and quaggavty group

1) Fix runtime to depend on initscripts
2) Fix quagga user to get quaggavty group

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoquagga: Modify code to build properly in tools and cumulus
Donald Sharp [Mon, 13 Jun 2016 23:10:17 +0000 (19:10 -0400)]
quagga: Modify code to build properly in tools and cumulus

The tools and cumulus directories were not properly
being included for the 'make dist' step to allow
for proper distribution of code.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agotools: Use the now included start-stop-daemon
Donald Sharp [Mon, 13 Jun 2016 23:08:43 +0000 (19:08 -0400)]
tools: Use the now included start-stop-daemon

Redhat does not have a way to run the start-stop-daemon.
This code is widely available on the internet and
very small.  Use the compiled start-stop-daemon(ssd)
if it is included with the system.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agodebian: Modifications to allow redhat to work properly
Donald Sharp [Mon, 13 Jun 2016 23:07:49 +0000 (19:07 -0400)]
debian: Modifications to allow redhat to work properly

Modify the control files to allow redhat to build properly.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agocumulus: Changes to make this code work for redhat
Donald Sharp [Mon, 13 Jun 2016 23:05:17 +0000 (19:05 -0400)]
cumulus: Changes to make this code work for redhat

Modify code base to allow rpm building.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoredhat: Changes to allow Cumulus start/stop methodology
Donald Sharp [Mon, 13 Jun 2016 23:00:24 +0000 (19:00 -0400)]
redhat: Changes to allow Cumulus start/stop methodology

Change the redhat .spec and control files to allow
redhat systemd interaction to be the same as
the debian style.  This will allow users
to use Quagga consistently across platforms.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoredhat: V6 compilation is on by default
Donald Sharp [Mon, 13 Jun 2016 16:54:39 +0000 (12:54 -0400)]
redhat: V6 compilation is on by default

Let's not call it out as a separate item
anymore.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoQuagga: bgpd needs extra neighbor and route json attributes for SNMP BGP4 MIB
Sam Tannous [Mon, 13 Jun 2016 22:39:57 +0000 (15:39 -0700)]
Quagga: bgpd needs extra neighbor and route json attributes for SNMP BGP4 MIB

Ticket: CM-11344
Reviewed By: dwalton, dsharp
Testing Done: built and tested amd64 debs

This patch adds the peerID JSON attribute for routes for show ip bgp json.
It also corrects the bgpTimerLastWrite in show ip bgp neigh json as well
as adds bgpInUpdateElapsedTimeMsecs, lastErrorCodeSubcode, and connectRetryTimer.
These are needed for the bgp4 mib implementation (rfc 4273) from the json
output of vtysh commands.

8 years agoMerge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into...
Don Slice [Mon, 13 Jun 2016 13:17:25 +0000 (09:17 -0400)]
Merge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into cmaster-next

8 years agoospfd/ospf6d/zebra: Change interface bandwidth range and auto-cost range to 100G
Don Slice [Mon, 13 Jun 2016 13:06:45 +0000 (09:06 -0400)]
ospfd/ospf6d/zebra: Change interface bandwidth range and auto-cost range to 100G

Prior to this change, interface bandwidth could not be defined above 10G. With
the use of higher speed interfaces, the ability to effectively define the path
links was highly impacted. Additionally, the default auto-cost reference-bandwidth
for ospf and ospfv3 was set to 100M, which relects a much earlier time.  Changed both
the range of interface bandwidth definitions and reference bandwidths to be up to
100G.  Set the default interface bandwidth (if not defined) to 10G to make the ratio
continue to cause a cost of 10 as before.  Manual testing as well as ospf-min and
ospf-smoke passed successfully.

Ticket: CM-10756
Signed-of-by: Don Slice
Reviewed-by: Donald Sharp
8 years agobgpd, lib, vtysh: hook up bgp ENCAP CLI node
Lou Berger [Tue, 12 Jan 2016 18:42:04 +0000 (13:42 -0500)]
bgpd, lib, vtysh: hook up bgp ENCAP CLI node

Signed-off-by: Lou Berger <lberger@labn.net>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit a3fda886cdd48b6d8c421ebb1401142fa9ee93b0)

Conflicts:
bgpd/bgp_vty.c
bgpd/bgpd.c
vtysh/vtysh_config.c

8 years agobgpd: encap: add encap SAFI (RFC5512)
Lou Berger [Tue, 12 Jan 2016 18:42:02 +0000 (13:42 -0500)]
bgpd: encap: add encap SAFI (RFC5512)

Adds RFC5512 and Encapsulation Attribute.

Signed-off-by: Lou Berger <lberger@labn.net>
(cherry picked from commit 298cc2f688dbadf0a447fcd06ae8e20fa5006ce4)

Conflicts:
bgpd/Makefile.am
bgpd/bgp_attr.c
bgpd/bgp_open.c
bgpd/bgp_packet.c
bgpd/bgp_route.c
bgpd/bgp_vty.c
bgpd/bgpd.c

8 years agobgpd: Fixes and updates for VPNv6
vivek [Sat, 11 Jun 2016 18:36:42 +0000 (11:36 -0700)]
bgpd: Fixes and updates for VPNv6

VPNv6 changes picked from upstream needed fixes and updates due to some
fundamental changes implemented by Cumulus (BGP update-groups, RFC 5549
and nexthop setting etc.) which aren't present upstream.

Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com>
Updates: 945c8fe8ecd326bb86c6093b73dff4c8985

8 years agozebra: Fix zebra to exit on recvmsg buffer overrun
Donald Sharp [Mon, 23 May 2016 21:22:24 +0000 (17:22 -0400)]
zebra: Fix zebra to exit on recvmsg buffer overrun

When zebra receives a recvmsg buffer from the kernel
silently exit so that watchquagga will notice and then
restart zebra.

Ticket: CM-11130
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Reviewed-by: Vivek Venkatraman <vivek@cumulusnetworks.com>
8 years agoBGP:Fix for BFD sessions not getting replayed after quagga restart
radhika [Sat, 21 May 2016 08:16:14 +0000 (01:16 -0700)]
BGP:Fix for BFD sessions not getting replayed after quagga restart

Signed-off-by: Radhika Mahankali <radhika@cumulusnetworks.com>
Reviewed-by: Donald Sharp <sharpd@cumulusnetworks.com>
Reviewed-by: Kanna Rajagopal <kanna@cumulusnetworks.com>
Ticket: CM-11055
Reviewed By: CCR-4773
Testing Done: Unit, PTM smoke, BGP neighbor smoke

Issue: bgpd is not replaying the BFD registrations to PTM after quagga restart.

Root Cause: This problem happens when BFD configuration is part of the peer group template. Currently, the BFD configuration is being copied to the peer from template as part of the AF (address family) configuration. But, when the saved config is used after the quagga restart the peer group template is applied to the peer before the AF configuration is configured for the template. Due to this the BFD configuration never gets copied from the template to the peer and the BGP peers have no BFD configuration after the restart

Sample config which failed:
router bgp 100
bgp router-id 10.10.0.1
no bgp default ipv4-unicast
bgp bestpath as-path multipath-relax
neighbor dpeergrp_2 peer-group
neighbor dpeergrp_2 remote-as 100
neighbor dpeergrp_2 bfd
neighbor dpeergrp_2 advertisement-interval 1
neighbor dpeergrp_2 timers connect 1
neighbor dpeergrp_4 peer-group
neighbor dpeergrp_4 remote-as 400
neighbor dpeergrp_4 bfd
neighbor dpeergrp_4 advertisement-interval 1
neighbor dpeergrp_4 timers connect 1
neighbor swp2s0.1 interface peer-group dpeergrp_2
neighbor swp18s3.1 interface peer-group dpeergrp_4
!
address-family ipv4 unicast
redistribute connected route-map redist
neighbor dpeergrp_2 activate
neighbor dpeergrp_2 next-hop-self
neighbor dpeergrp_2 default-originate
neighbor dpeergrp_2 soft-reconfiguration inbound
neighbor dpeergrp_4 activate
neighbor dpeergrp_4 next-hop-self
neighbor dpeergrp_4 default-originate
neighbor dpeergrp_4 soft-reconfiguration inbound
maximum-paths 14
exit-address-family

Fix: Moved the BFD config copy from the peer group AF config copy function to the main peer group config copy function.

8 years agolib: Fix some poll semantics
Donald Sharp [Thu, 19 May 2016 13:56:35 +0000 (09:56 -0400)]
lib: Fix some poll semantics

Two Fixes:

1) When a fd has both read and write as a .events.
(POLLHUP | POLLIN | POLLOUT) and a
thread_cancel_read_write call is executed
from a protocol, the code was blindly removing
the fd from consideration at all.

2) POLLNVAL was being evaluated before POLLIN|POLLOUT
were being evaluated.  While I didn't see a case
of POLLNVAL being included with other .revent flags
I decided to move the POLLNVAL and POLLHUP handling
to the same section of code.

Additionally the function thread_cancel_read_write
was poorly named and let me to poorly implement
the poll version of it.  I've renamed the function
thread_cancel_read_or_write in an attempt to
make this problem moot in the future.

Ticket: CM-11027
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
(cherry picked from commit f6da66a913bcae1d3f75c55f24e72e97288af619)

8 years agobgpd: remove vrf->iflist deleted to avoid a crash
Don Slice [Fri, 10 Jun 2016 13:58:03 +0000 (06:58 -0700)]
bgpd: remove vrf->iflist deleted to avoid a crash

Ticket: CM-11327
Signed-off-by: Don Slice
Reviewed-by: Donald Sharp
Testing Done: Manual testing, bgp-min, vrf-min, bgp-smoke, vrf-smoke all successful

When bgp was configured in a vrf and then deleted, the vrf->iflist
was being deleted from the vrf.  Since the vrf itself was not deleted,
it was assumed in later calls that the vrf->iflist was still there
and when it was referenced, the crash occurred.

8 years agodebian: Remove obsoleted configure options.
Donald Sharp [Sat, 4 Jun 2016 23:55:23 +0000 (19:55 -0400)]
debian: Remove obsoleted configure options.

configure.ac has moved on, catch debian up
with it.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoconfigure: Auto pick-up the correct json env
Donald Sharp [Sat, 4 Jun 2016 23:55:22 +0000 (19:55 -0400)]
configure: Auto pick-up the correct json env

Fix the code to allow Quagga to automatically
compile with the correct json library.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoconfigure: Ensure systemd development is present
Donald Sharp [Sat, 4 Jun 2016 23:55:21 +0000 (19:55 -0400)]
configure: Ensure systemd development is present

If a users specifies that they should use systemd
then ensure that the systemd can be compiled against it.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agobgpd: encap: add attribute handling
Lou Berger [Tue, 12 Jan 2016 18:42:01 +0000 (13:42 -0500)]
bgpd: encap: add attribute handling

Signed-off-by: Lou Berger <lberger@labn.net>
Reviewed-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit c3741789530ee824693fd606356acac2ad695f83)

Conflicts:
bgpd/Makefile.am
bgpd/bgp_attr.c
bgpd/bgp_attr.h
lib/memtypes.c

8 years agoMerge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into...
vivek [Fri, 10 Jun 2016 01:20:55 +0000 (18:20 -0700)]
Merge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into cmaster-next

8 years agobgpd: general MP/SAFI improvements
Lou Berger [Tue, 12 Jan 2016 18:41:59 +0000 (13:41 -0500)]
bgpd: general MP/SAFI improvements

This fixes some minor mixups particularly in MPLS-related SAFIs, as well
as doing some stylistic changes & adding comments.

Signed-off-by: Lou Berger <lberger@labn.net>
Reviewed-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 050defe816e4bd4cac7b028f69e45cb1974ca96d)

Conflicts:
bgpd/bgp_attr.c
bgpd/bgp_attr.h
bgpd/bgp_packet.c
bgpd/bgp_route.c
bgpd/bgp_route.h

8 years agopimd: Fix of using uninitialized Memory
Donald Sharp [Thu, 9 Jun 2016 19:16:14 +0000 (15:16 -0400)]
pimd: Fix of using uninitialized Memory

Valgrind is reporting that pimd is using uninitialized
memory for comparisons.  This commit addresses
the issues found there.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agovtysh json output not JSON for show ip bgp neigh json
Sam Tannous [Thu, 9 Jun 2016 16:26:06 +0000 (12:26 -0400)]
vtysh json output not JSON for show ip bgp neigh json

Ticket: CM-11350
Reviewed By: dsharp
Testing Done: built amd64 images and tested output of both json and non-json

Upstream patch was applied in wrong section of code so JSON
output contained plain text.   The upstream patch was
commit baa376fc1 (cherry picked from ef757700d0f)

This patch moves the text output to the correct if clause
and also adds a new JSON line for the same data.

Signed-off-by: Sam Tannous <stannous@cumulusnetworks.com>
Reviewed-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agolib: change command logging to be off by default, and add 'log_commands' to enable it.
Lou Berger [Tue, 17 May 2016 16:19:51 +0000 (12:19 -0400)]
lib: change command logging to be off by default, and add 'log_commands' to enable it.

8 years agolib: add facility to log all CLI commands
Lou Berger [Tue, 12 Jan 2016 18:41:49 +0000 (13:41 -0500)]
lib: add facility to log all CLI commands

Signed-off-by: Lou Berger <lberger@labn.net>
(cherry picked from commit c7f7e49a4f68c92152384582ff70d64609858170)

8 years agozebra/ioctl_solaris: Fix use of prefix2str in if_prefix_add/delete_ipv6
Martin Winter [Wed, 16 Sep 2015 02:12:31 +0000 (19:12 -0700)]
zebra/ioctl_solaris: Fix use of prefix2str in if_prefix_add/delete_ipv6

First argument of prefix2str pointed to ifc->address->prefix, but
no prefix exists in address. Should have been ifc->address.

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
(cherry picked from commit fe56125bbcbc0c503ae6bd0b934a4940c4693b4f)

8 years agobuild/solaris: create ioctl_solaris.h
David Lamparter [Tue, 15 Sep 2015 09:46:53 +0000 (02:46 -0700)]
build/solaris: create ioctl_solaris.h

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 285ed0c62af4f57902d5deacc621f290fdeec276)

8 years agoospfd: fix unused warning in ospf_write
David Lamparter [Tue, 15 Sep 2015 09:11:45 +0000 (02:11 -0700)]
ospfd: fix unused warning in ospf_write

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years ago*: make sure zebra.h is always included first
David Lamparter [Tue, 15 Sep 2015 08:53:09 +0000 (01:53 -0700)]
*: make sure zebra.h is always included first

zebra.h pulls in config.h, which results in fiddling with things like
__FILE_OFFSET_BITS. It must always be included first, in order to set
flags that influence the compiler via <features.h>.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 821df2cf18e5978cc7ab532a8695444380d08270)

8 years agolib/zclient: Consolidate error reporting for zclient_read_header
Donald Sharp [Thu, 17 Sep 2015 14:54:25 +0000 (10:54 -0400)]
lib/zclient: Consolidate error reporting for zclient_read_header

All functions that call zclient_read_header immediately turn around
and check to ensure that the version and marker fields are correct
Move this code into zclient_read_header

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
(cherry picked from commit a9d4cb33faa6af622240190a80f41c4672374925)

8 years agoospfd: Fix for 'no' + 'debug command' does not disable 'debug command'
Vystoropskyi, Sergii [Sun, 16 Aug 2015 13:25:36 +0000 (13:25 +0000)]
ospfd: Fix for 'no' + 'debug command' does not disable 'debug command'

"no debug ospf packet all detail" does not cancel "debug ospf packet all detail"
due to the code inconsistency in setting/unsetting debug flags.

* ospf_dump.c: added missing flags.
Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
(cherry picked from commit b075e8728f650b0850e20fdf8dde467440a24b28)

8 years agoospfd: Fast OSPF convergence
Michael Rossberg [Mon, 27 Jul 2015 05:56:25 +0000 (07:56 +0200)]
ospfd: Fast OSPF convergence

When considering small networks that have extreme requirements on
availability and thus convergence delay, the timers given in the OSPF RFC
seem a little “conservative”, i.e., the delay between accepted LSAs and the
rate at which LSAs are sent.  Cisco introduced two commands 'timers throttle
lsa all’ and 'timers lsa arrival’, which allow operators to tune these
parameters.

I have been writing a patch to also support 'timers lsa arrival’ fully and
‘timers throttle lsa all’ (without the throttling part) also in quagga.

8 years agoFix _netlink_route_debug message
Kaloyan Kovachev [Mon, 15 Jun 2015 14:08:48 +0000 (17:08 +0300)]
Fix _netlink_route_debug message

(cherry picked from commit 8c56b44de0fa8100b6f0b367dbc604d41b94025f)

8 years agozebra: fix VRF code for *BSD
David Lamparter [Tue, 2 Jun 2015 06:31:38 +0000 (08:31 +0200)]
zebra: fix VRF code for *BSD

There seems to be no rtm_table in struct rt_msghdr, at least on the
systems I have access to...

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit d6cf5134c05a7890738411852d9357ee5bb322f3)

8 years agoospf6d, bgpd: avoid calling if_nametoindex
Feng Lu [Fri, 22 May 2015 09:39:55 +0000 (11:39 +0200)]
ospf6d, bgpd: avoid calling if_nametoindex

As the comments in if.h, it is better to call ifname2ifindex()
instead of if_nametoindex().

And ifname2ifindex() can work for VRF by appending a parameter
while if_nametoindex() can not.

Signed-off-by: Feng Lu <lu.feng@6wind.com>
Reviewed-by: Alain Ritoux <alain.ritoux@6wind.com>
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: Vincent JARDIN <vincent.jardin@6wind.com>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 395828eea809e8b2b8c5824d3639cefedd7aa9f0)

8 years agozebra: use prefix2str for logging where possible
Timo Teräs [Sat, 23 May 2015 08:08:41 +0000 (11:08 +0300)]
zebra: use prefix2str for logging where possible

This makes code more robust, consice and readable.

Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit be6335d682c5ee1b6930345193eda875705fbab2)

8 years agozebra/vty: use prefix2str and unify show ip/ipv6 route code
Timo Teräs [Sat, 23 May 2015 08:08:40 +0000 (11:08 +0300)]
zebra/vty: use prefix2str and unify show ip/ipv6 route code

Use prefix2str where possible. As now ip/ipv6 are practically
identical, they are merged removing unneeded code duplication.

Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 53a5c39c705f917567d5b1764f1fe12ad5c5e577)

8 years agolib: make prefix2str simpler to use, and use it in zclient
Timo Teräs [Sat, 23 May 2015 08:08:39 +0000 (11:08 +0300)]
lib: make prefix2str simpler to use, and use it in zclient

Returning the buffer allows using it in the logging functions
in easier way. This also makes the API consistent with sockunion.

Add also PREFIX_STRLEN to be the generic buffer length required
for any prefix string representation.

Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 41eb9a4305fbcb206c900a18af7df7115d857d60)

8 years agolib: allow caller to provide prefix storage in sockunion2hostprefix
Timo Teräs [Fri, 22 May 2015 10:40:57 +0000 (13:40 +0300)]
lib: allow caller to provide prefix storage in sockunion2hostprefix

Avoids a dynamic allocation which is usually freed immediate afterwards.

Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agobgpd: tests - add null pointer protection to fix bgp test failures
Lou Berger [Tue, 12 Jan 2016 18:41:58 +0000 (13:41 -0500)]
bgpd: tests - add null pointer protection to fix bgp test failures

Signed-off-by: Lou Berger <lberger@labn.net>
(cherry picked from commit d5d5e3e04fc41b9a89b7ce9049fd322bdbde2e4d)

Conflicts:
bgpd/bgp_nexthop.c

8 years agobgpd: Do not process workqueue upon instance delete
vivek [Thu, 9 Jun 2016 01:14:17 +0000 (18:14 -0700)]
bgpd: Do not process workqueue upon instance delete

During instance cleanup, an earlier patch walked the workqueue in order
to process queued routes of the instance. However, since the workqueue
is not per instance, the code walks and immediately processes all routes
across all instances.

This may not be ideal in the presence of VRFs, when multiple instances
will be a fact. Revert that part of the change from earlier patch. This
needs to be revisited later for a better solution.

Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com>
Updates: bb86c6017eccd03ea1554c7bdef5949cf676f208

8 years agoMerge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into...
vivek [Thu, 9 Jun 2016 00:58:55 +0000 (17:58 -0700)]
Merge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into cmaster-next

8 years agobgpd: improve cleanup in bgp_delete()
Lou Berger [Tue, 12 Jan 2016 18:41:57 +0000 (13:41 -0500)]
bgpd: improve cleanup in bgp_delete()

Signed-off-by: Lou Berger <lberger@labn.net>
(cherry picked from commit 82dd707988b7481e203cab058c92f0b3041dd558)

Conflicts:
bgpd/bgp_nexthop.h
bgpd/bgp_route.c
bgpd/bgp_routemap.c
bgpd/bgp_zebra.h
bgpd/bgpd.c
bgpd/bgpd.h

8 years agoMerge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into...
Daniel Walton [Thu, 9 Jun 2016 00:49:09 +0000 (17:49 -0700)]
Merge branch 'cmaster-next' of ssh://stash.cumulusnetworks.com:7999/quag/quagga into cmaster-next

8 years agozebra: Fix comparison warning
Donald Sharp [Wed, 8 Jun 2016 19:30:48 +0000 (15:30 -0400)]
zebra: Fix comparison warning

It's possible to have a comparison where
MULTIPATH_NUM is greater than the size of
data that a u_char supports for nexthop_num

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoripngd: allow to enable/disable the ECMP feature
Feng Lu [Fri, 22 May 2015 09:39:54 +0000 (11:39 +0200)]
ripngd: allow to enable/disable the ECMP feature

Introduce a new command "[no] allow-ecmp" to enable/disable the
ECMP feature in RIPng. By default, ECMP is not allowed.

Once ECMP is disabled, only one route entry can exist in the list.

* ripng_zebra.c: adjust a debugging information, which shows the number
                 of nexthops according to whether ECMP is enabled.
* ripngd.c: ripng_ecmp_add() will reject the new route if ECMP is not
            allowed and some entry already exists.
            A new configurable command "allow-ecmp" is added to control
            whether ECMP is allowed.
            When ECMP is disabled, ripng_ecmp_disable() is called to
            remove the multiple nexthops.
* ripngd.h: Add a new member "ecmp" to "struct ripng", indicating whether
            ECMP is allowed or not.

Signed-off-by: Feng Lu <lu.feng@6wind.com>
Reviewed-by: Alain Ritoux <alain.ritoux@6wind.com>
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 72855b16b72e9ad2c7eb0c0bfd8f5985f779608f)

8 years agoripngd: add ECMP support
Feng Lu [Fri, 22 May 2015 09:39:53 +0000 (11:39 +0200)]
ripngd: add ECMP support

* Each node in the routing table is changed into a list, holding
  the multiple equal-cost paths.

* If one of the multiple entries gets less-preferred (greater
  metric or greater distance), it will be directly deleted instead
  of starting a garbage-collection timer for it.
  The garbage-collection timer is started only when the last entry
  in the list gets INFINITY.

* Some new functions are used to maintain the ECMP list. And hence
  ripng_route_process(), ripng_redistribute_add() and ripng_timeout()
  are significantly simplified.

* ripng_zebra_ipv6_add() and ripng_zebra_ipv6_delete() now can share
  the common code. The common part is moved to ripng_zebra_ipv6_send().

Signed-off-by: Feng Lu <lu.feng@6wind.com>
Reviewed-by: Alain Ritoux <alain.ritoux@6wind.com>
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agoisisd: always print adj->sysid (clang 3.6 warning)
David Lamparter [Wed, 20 May 2015 17:06:12 +0000 (19:06 +0200)]
isisd: always print adj->sysid (clang 3.6 warning)

As any new compiler version, clang 3.6 has new warnings, one of these
being that it now warns for testing whether the address of an array will
be true.

Of course there is no point in this check for the sysid, so let's always
just print the sysid.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agolib/vty: don't clear output buffer on input EOF
David Lamparter [Thu, 14 May 2015 12:24:06 +0000 (14:24 +0200)]
lib/vty: don't clear output buffer on input EOF

A VTY's input can be closed without the output becoming unavailable.
This happens both on stdio when stdin ends, as well as over TCP when an
unidirectional input shutdown() happens.

In such a case, resetting the output buffer is not appropriate since
there might still be data to be successfully written.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agolib/vty: add vty_stdio at-close hook
David Lamparter [Tue, 12 May 2015 19:56:18 +0000 (21:56 +0200)]
lib/vty: add vty_stdio at-close hook

This is intended to be used for either "exit on close", "fork on close"
or "reopen vty on close" functionality for the stdio vty.  Which of
these options to take depends on the context, the use case right now is
test programs exiting on EOF.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 464ccf36b4aa1b942cad413ea30267b4bf9e6315)

8 years agolib/vty: put stdin in raw mode for vty
David Lamparter [Tue, 5 May 2015 09:04:46 +0000 (11:04 +0200)]
lib/vty: put stdin in raw mode for vty

The interactive CLI actually works just fine, if we just put the
terminal in raw mode to get keystrokes as they come.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit ba53a8fdecef07577dcc4109e5c82bb124d49c58)

8 years agolib/vty: add vty_stdio()
David Lamparter [Thu, 30 May 2013 14:33:45 +0000 (16:33 +0200)]
lib/vty: add vty_stdio()

this introduces a new public/API function to the vty code for opening a
VTY on stdin/stdout.  Intended for unrestricted use by the individual
daemons, i.e. "offical API".

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agolib/vty: add separate output fd support to VTYs
David Lamparter [Thu, 30 May 2013 14:31:49 +0000 (16:31 +0200)]
lib/vty: add separate output fd support to VTYs

to be used with stdin/stdout terminals, this adds support for writing to
a different FD than we're reading from.  Also fixes error messages from
config load being written to stdin.

[v2: fixed config write]
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 4715a53b4d390e72a06c864a6a505971841e3dc9)

8 years agoospfd: Remove another odd flooding hack in opaque LSA code
Paul Jakma [Fri, 23 Jan 2015 16:43:49 +0000 (16:43 +0000)]
ospfd: Remove another odd flooding hack in opaque LSA code

* ospf_opaque.c: (ospf_opaque_adjust_lsreq) Odd hack to general OSPF
  database exchange but made to act only on opaque LSAs. It's either covering
  up bugs in the flooding code or its wrong. If it's covering up bugs, those
  would affect all LSAs and should be fixed at a lower layer in ospfd, indeed
  perhaps those bugs are long fixed anyway (?). Alternatively, it's just plain
  wrong. Nuke.
  (ospf_opaque_exclude_lsa_from_lsreq) helper to above, nuke.
* ospf_packet.c: Nuke call to ospf_opaque_adjust_lsreq.

Tested-by: olivier.dugeon@orange.com
8 years agolib: assert(0) still needs a return
David Lamparter [Wed, 13 May 2015 10:44:50 +0000 (12:44 +0200)]
lib: assert(0) still needs a return

assert(0) is not guaranteed to not return since assert() in general can
be optimised out when building without debug / with optimisation.  This
breaks the build in clang, which warns/errors about the missing return.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit f1fc327c7eb00634d2c2b08c2a6f6e44a626ef04)

8 years ago*: fix more initialisers (for BSD)
David Lamparter [Tue, 21 Apr 2015 08:13:07 +0000 (10:13 +0200)]
*: fix more initialisers (for BSD)

FreeBSD and NetBSD spew a few more warnings about variable initialisers.
Found with OSR's/NetDEF's fancy new CI system.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agolib: fix "reduce strcmp in CLI" fallout (10bac801)
David Lamparter [Tue, 12 May 2015 15:18:04 +0000 (17:18 +0200)]
lib: fix "reduce strcmp in CLI" fallout (10bac801)

In "lib/cli: reduce strcmp in CLI hot paths", I failed to notice that
CMD_VARIABLE as a boolean test covers a superset of the other types of
variables.  Thus, the patch broke processing of IP/IPv6/Integer range
parameters in the CLI.

Fix by some reordering and introducing TERMINAL_RECORD macro (which
marks whether a given terminal type is a parameter) to be used in places
where the check is really for all kinds of variables.

Reported-by: Timo Teräs <timo.teras@iki.fi>
Tested-by: Martin Winter <mwinter@netdef.org>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agobgpd: speed up "no-hit" withdraws for routeservers
David Lamparter [Mon, 13 Apr 2015 07:50:00 +0000 (09:50 +0200)]
bgpd: speed up "no-hit" withdraws for routeservers

This accelerates handling of incoming Withdraw messages for routes that
don't exist in the table to begin with.  Cisco IOS 12.4(24)T4 has a bug
in this regard - it sends withdraws instead of doing nothing for
prefixes that are filtered.

Pulling up the adj_in removal in Quagga should have no ill effect, but
we can avoid the costly iteration over all rsclients if there was no
adj_in entry.

Performance impact of this change on routeserver with 3 buggy peers,
startup/sync time:

before patch:  143.12 seconds (user cpu)
after patch:     7.01 seconds (user cpu)

Many thanks to Nick Hilliard & INEX for providing real-world test data!

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Acked-by: Paul Jakma <paul@jakma.org>
8 years agoospfd: Remove the blocking of opaque LSAs origination & flooding 'optimisation'
Paul Jakma [Tue, 20 Jan 2015 15:45:36 +0000 (15:45 +0000)]
ospfd: Remove the blocking of opaque LSAs origination & flooding 'optimisation'

* Opaque support contains some kind of hack/optimisation to
  origination/flooding to suppress some origins/floods until an opaque LS
  Acks are received.  Previous versions of the code have already been shown
  to have bugs in them (see e16fd8a5, e.g.). It seems over-complex and fragile,
  plus its conceptually the wrong place to try implement flooding hacks that,
  AFAICT, do not depend particularly on the semantics of opaque LSA.

  Nuke.

Tested-by: Olivier Dugeon <olivier.dugeon@orange.com>
8 years agolib/cli: reduce strcmp in CLI hot paths
David Lamparter [Tue, 5 May 2015 09:10:20 +0000 (11:10 +0200)]
lib/cli: reduce strcmp in CLI hot paths

Er, no idea how anyone could ever have thought that it would be a good
idea to have a zillion of strcmp() calls in the CLI's active paths, just
to compare against things like "A.B.C.D".

Reduces 40k prefix list load time from 1.65s to 1.23s (1.34:1).

Acked-by: Paul Jakma <paul@jakma.org>
[v2: killed CMDS_* macros]
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 10bac80195cf5a781da6e4415e6580fd7080f734)

8 years agolib: constify sockunion api
Timo Teräs [Wed, 29 Apr 2015 06:43:01 +0000 (09:43 +0300)]
lib: constify sockunion api

Add const to read-only api calls.

Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 81b139bdd530adda045d22a4daf0054b89703dab)

8 years agozebra: fix rtadv check for non-glibc linux
Timo Teräs [Wed, 29 Apr 2015 06:43:00 +0000 (09:43 +0300)]
zebra: fix rtadv check for non-glibc linux

Default RTADV enabled for non-glibc linux (fixes check for musl libc).

Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agozebra: fix build with rtadv disabled
Timo Teräs [Wed, 29 Apr 2015 06:42:59 +0000 (09:42 +0300)]
zebra: fix build with rtadv disabled

Otherwise we get warning on rtadv_init() prototype not being
defined when compiling rtadv.c (as dummy stub is provided always).

Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agobuild: add --enable-werror
David Lamparter [Tue, 3 Mar 2015 09:00:43 +0000 (10:00 +0100)]
build: add --enable-werror

This allows enabling -Werror in a consistent way.  Note that this is
different from just specifiying it in CFLAGS, since that would either
break configure tests (if done on ./configure), or would override
configure's CFLAGS (if done on make).

Using --enable-werror instead provides a new WERROR variable that is
additionally used during make with a consistent set of warning flags.

The tests/ directory is exempt.  (Rationale being, better to have more
tests than pedantically complain about them.)

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agobuild: determine CFLAGS more intelligently
David Lamparter [Tue, 3 Mar 2015 08:55:51 +0000 (09:55 +0100)]
build: determine CFLAGS more intelligently

Instead of hardcoding some compiler detection, this just checks which
CFLAGS actually work with the compiler specified by the user.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 3a7e83c2387885075c9ecf1912dd6c9399c6947a)

8 years agovtysh: drop unused variables & RETSIGTYPE
David Lamparter [Wed, 4 Mar 2015 06:18:24 +0000 (07:18 +0100)]
vtysh: drop unused variables & RETSIGTYPE

Drop unused return values in vtysh.  Also gets rid of the rather funny
prototyping of signal setup in vtysh - which as a side effect makes it
not need AC_TYPE_SIGNAL in configure.ac anymore.  It wasn't used
sensibly to begin with...

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 6769f43de9d595b935f2ebf1cae1428e1d1a3a5f)

8 years agovtysh: fix function prototypes
David Lamparter [Wed, 4 Mar 2015 06:07:01 +0000 (07:07 +0100)]
vtysh: fix function prototypes

This makes a whole bunch of vtysh functions static, fixes prototypes for
a few more, and masks user_free() and user_write_config() (both unused.)

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit a9eb9063071437f5cde3b78adf273b428c49d378)

8 years agovtysh: don't use '\0' as NULL
David Lamparter [Tue, 3 Mar 2015 08:06:51 +0000 (09:06 +0100)]
vtysh: don't use '\0' as NULL

for some reason, the vty code was using '\0' in place of NULL.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit a91a3bac14976c04bf22b20c7e4bada787ec79b1)

8 years agoospf6d: fix pointer arithmetic warning
David Lamparter [Sun, 19 Apr 2015 12:54:03 +0000 (14:54 +0200)]
ospf6d: fix pointer arithmetic warning

caddr_t was signed; this buffer size comparison is better done in
unsigned.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 3cf4053a9e832408fad33a8246ecbd189f23a956)

8 years agoospf6d: oi->cost is uint32, not short
David Lamparter [Tue, 3 Mar 2015 08:08:20 +0000 (09:08 +0100)]
ospf6d: oi->cost is uint32, not short

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 72c69d434840598a158747ba9f69dad536f96cea)

8 years agoospf6d: use existing union, avoid strict-aliasing
David Lamparter [Tue, 3 Mar 2015 09:30:27 +0000 (10:30 +0100)]
ospf6d: use existing union, avoid strict-aliasing

There are preexisting fields u.lp.id and u.lp.adv_router in struct
prefix that do the same thing as these type-punning pointer derefs.
Use these and shut up the strict-aliasing warnings.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 0de0138a9146074f268245193e45c9376d998722)

8 years agolib, vtysh: reduce unneccessary C extension usage
David Lamparter [Tue, 3 Mar 2015 08:08:05 +0000 (09:08 +0100)]
lib, vtysh: reduce unneccessary C extension usage

We're only supporting GCC, Clang and ICC; but there's no reason to use
nonstandard C constructs if they don't actually provide any benefit.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 71f55f38cb3dd804176e7f382f52b75ddcd437de)

8 years agolib: use const consistently for zserv path
David Lamparter [Tue, 3 Mar 2015 07:57:02 +0000 (08:57 +0100)]
lib: use const consistently for zserv path

The global variable is missing its const, but the accessor function has
a meaningless extra const in exchange...

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agopimd: Fix register message checksum
Donald Sharp [Wed, 8 Jun 2016 15:47:33 +0000 (11:47 -0400)]
pimd: Fix register message checksum

The register message checksum was being calculated over
the first 4 bytes of the packet, instead of the first
8 bytes.  From the RFC:

PIM Version, Type, Reserved, Checksum
        Described in Section 4.9. Note that in order to reduce
        encapsulation overhead, the checksum for Registers is done only
        on the first 8 bytes of the packet, including the PIM header and
        the next 4 bytes, excluding the data packet portion.  For
        interoperability reasons, a message carrying a checksum
        calculated over the entire PIM Register message should also be
        accepted.  When calculating the checksum, the IPv6 pseudoheader
        "Upper-Layer Packet Length" is set to 8.

Ticket: CM-11265
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoredhat: Cleanup some unneeded parameters
Donald Sharp [Sun, 5 Jun 2016 22:04:14 +0000 (18:04 -0400)]
redhat: Cleanup some unneeded parameters

In the Quagga.spec file we have these fixes:

1) rpmversion was being defined but never used in it's scope.
Made it global so it couldbe properly referenced.

2) Use texi2html to tell you it's version instead of rpm
Note for the future to convert to mock we will need to
find a different methodology to handle this.

3) vtysh/isisd and pimd are turned on by default
No need to call them out.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agodoc: Add quagga.1 to the distribution
Donald Sharp [Sun, 5 Jun 2016 22:02:24 +0000 (18:02 -0400)]
doc: Add quagga.1 to the distribution

The quagga.1 file was not part of the distribution
and was not being included in the dist tar ball
which caused rpm builds to fail.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoredhat: Cleanup redhat options.
Donald Sharp [Sun, 5 Jun 2016 20:39:31 +0000 (16:39 -0400)]
redhat: Cleanup redhat options.

Start the cleanup of the redhat .spec file:

1) Remove snmp, it's hopelessly broken.
2) Multiple with_vtysh lines.
3) Fix vty group to be quaggavty

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoospfd: Fix oi->nbr_self pointer dereference
Donald Sharp [Fri, 10 Jun 2016 18:32:22 +0000 (14:32 -0400)]
ospfd: Fix oi->nbr_self pointer dereference

With commit 1b31375427008aaf980f68d95f50007f600c8ae1
we have a situation where it is possible that the
oi->nbr_self has not been properly set.  When
calling the function that sets the nbr_self data
make sure that we have a pointer that works for it.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agoospfd: fix - correct neighbor index on changing/p2p/virtual links
Jafar Al-Gharaibeh [Thu, 21 Apr 2016 21:22:33 +0000 (16:22 -0500)]
ospfd: fix - correct neighbor index on changing/p2p/virtual links

ospfd keeps a list of neighbor routers for each configured interface. This
 list is indexed using the neighbor router id in case of point-to-point and
 virtual link types, otherwise the list is indexed using the neighbor's
 source IP (RFC 2328, page 96). The router adds itself as a "pseudo" neighbor
 on each link, and also keeps a pointer called (nbr_self) to the neighbor
 structure. This takes place when the interface is first configured. Currently
 ospfd adds this pseudo neighbor before the link parameters are fully configure,
 including whether the link type is point-to-point or virtual link. This causes
 the pseudo neighbor to be always indexed using the source IP address regardless
 of th link type. For point-to-point and virtual links, this causes the lookup
 for the pseudo neighbor to always fail because the lookup is done using the
 router id whereas the neighbor was added using its source IP address.
 This becomes really problematic if there is a state change that requires a
 rebuild of nbr_self, changing the router id for example. When resetting
 nbr_self, the router first tries to remove the pseudo neighbor form its
 neighbor list on each link by looking it up and resetting any references to it
 before freeing the neighbor structure. since the lookup fails to retrieve any
 references in the case of point-to-point and virtual links the neighbor
 structure is freed leaving dangling references to it. Any access to the
 neighbor list after that is bound to stumble over this dangling pointer
 causing ospfd to crash.

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
Tested-by: NetDEF CI System <cisystem@netdef.org>
(cherry picked from commit bb01bdd740339b0c07d8ed0786811801b2a79192)

8 years agoconfigure.ac: Add back HAVE_SYSTEMD
Donald Sharp [Fri, 10 Jun 2016 18:53:53 +0000 (14:53 -0400)]
configure.ac: Add back HAVE_SYSTEMD

When the change was made to add some additional
code to make sure systemd was actually installed
on the system, the HAVE_SYSTEMD #define was
accidently removed.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agopimd: Rehookup the redistribution code
Donald Sharp [Fri, 3 Jun 2016 10:20:05 +0000 (06:20 -0400)]
pimd: Rehookup the redistribution code

Due to rewrite of the redistribution mechanism in ZEBRA,
rehookup the redist statements to pimd from zebra.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agozebra: Fix last sent command to protocol
Donald Sharp [Fri, 3 Jun 2016 08:56:10 +0000 (04:56 -0400)]
zebra: Fix last sent command to protocol

With the addition of VRF's we were not properly
storing the last sent command to individual
protocols from zebra.  This commit fixes this:

Pre-Fix:
Client: bgp
------------------------
FD: 14
Route Table ID: 0
Connect Time: 00:10:51
Not registered for Nexthop Updates
Last Msg Rx Time: 00:10:51
Last Msg Tx Time: 00:00:04
Last Rcvd Cmd: ZEBRA_REDISTRIBUTE_ADD
Last Sent Cmd: (null)

Post-Fix:
Client: bgp
------------------------
FD: 14
Route Table ID: 0
Connect Time: 00:02:42
Not registered for Nexthop Updates
Last Msg Rx Time: 00:02:42
Last Msg Tx Time: 00:00:09
Last Rcvd Cmd: ZEBRA_REDISTRIBUTE_ADD
Last Sent Cmd: ZEBRA_INTERFACE_UP

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agopimd: Make pim_pkt_dump use standard lib functions
Donald Sharp [Tue, 7 Jun 2016 15:00:53 +0000 (11:00 -0400)]
pimd: Make pim_pkt_dump use standard lib functions

pim_pkt_dump was creating a custom function to dump
detailed packet data.  Switch it over to use
zlog_hexdump.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agobgpd: Fix Missing capability codes in data structure
Donald Sharp [Tue, 7 Jun 2016 14:49:35 +0000 (10:49 -0400)]
bgpd: Fix Missing capability codes in data structure

Forward port of a fix from upstream introduced
the need to have data on the new capability codes
that have been introduced.

This commit adds in the missing capabilities.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Reviewed-by: Daniel Walton <dwalton@cumulusnetworks.com>
8 years agozebra: clean up misc_null pragmas
David Lamparter [Tue, 3 Mar 2015 08:14:46 +0000 (09:14 +0100)]
zebra: clean up misc_null pragmas

The no-op alternatives provided in misc_null trigger a few warnings
since they provide functions / use pragmas without prototypes.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit a3466abd93f83424f9f83e56282e42188e1f94ce)

8 years agozebra: Cleanup missed cherry-pick
Donald Sharp [Tue, 7 Jun 2016 13:38:02 +0000 (09:38 -0400)]
zebra: Cleanup missed cherry-pick

Cherry-pick of 2e5ca49758543 was missing the
removal of some files.

Since these are not referenced in the build anymore
it's ok to remove them.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
8 years agozebra: use prototypes/includes in rt_netlink
David Lamparter [Wed, 4 Mar 2015 06:05:39 +0000 (07:05 +0100)]
zebra: use prototypes/includes in rt_netlink

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 48ab06b43040bb27d267bb165eedf9e496eb865b)

8 years agozebra: remove unused netlink_route()/kernel_rtm_ipv6()
David Lamparter [Tue, 3 Mar 2015 07:57:49 +0000 (08:57 +0100)]
zebra: remove unused netlink_route()/kernel_rtm_ipv6()

kernel_delete_ipv6_old(), removed in 51bdeba a little while ago, was the
last user of netlink_route() and kernel_rtm_ipv6().  Everything else
uses the _multipath variants of these functions.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 872b0dc0537b62503d98bafd3075553795c847cb)

8 years agoisisd: remove unused process_is_hello()
David Lamparter [Tue, 3 Mar 2015 07:56:05 +0000 (08:56 +0100)]
isisd: remove unused process_is_hello()

The code uses process_lan_hello() or process_p2p_hello().  The unused
process_is_hello() seems to be a leftover generic version.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agoisisd: fix size_t confusions
David Lamparter [Fri, 10 Apr 2015 07:10:11 +0000 (09:10 +0200)]
isisd: fix size_t confusions

isisd had a few places that mixed up size_t vs. unsigned long, and %zd
vs. %ld.  Clean out.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 01da6176b88fe59b3c6ceaf3630df88046c83159)

8 years agoisisd: assorted fixes (unused variables, static)
David Lamparter [Wed, 4 Mar 2015 06:13:38 +0000 (07:13 +0100)]
isisd: assorted fixes (unused variables, static)

This just mops up a few warnings in isisd.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit f50ee93d12f8213a048a04fcf7d73e12662288e5)

8 years agoisisd: fix minor & vs. && mix-up
David Lamparter [Tue, 3 Mar 2015 08:07:43 +0000 (09:07 +0100)]
isisd: fix minor & vs. && mix-up

apparently we were displaying all IPv6 reachabilities as external.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agoisisd: don't use POSIX reserved y1/yn names
David Lamparter [Tue, 3 Mar 2015 07:56:35 +0000 (08:56 +0100)]
isisd: don't use POSIX reserved y1/yn names

y1 and yn are POSIX standard names for Bessel functions.  For
consistency, just rename all of these variables from "y" to "yy".

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years agobgpd, zebra: fix struct/pointer sizeof mixups
David Lamparter [Tue, 3 Mar 2015 07:54:54 +0000 (08:54 +0100)]
bgpd, zebra: fix struct/pointer sizeof mixups

Two places were taking sizeof(pointer) instead of the sizeof(struct),
while performing operations on the struct.  Both are initialisation
functions;  I guess we haven't seen fallout since they weren't critical.
Fix anyway.

[v2: fix mistake that actually broke bgpd RS workqueue init]
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit d43f8b39b075fe60e0c8fdb33b07b284d3fae503)

8 years ago*: add/cleanup initialisers
David Lamparter [Tue, 3 Mar 2015 08:07:25 +0000 (09:07 +0100)]
*: add/cleanup initialisers

There were some (inconsequential) warnings about uninitialised use of
variables.  Also, in one case, sub-structs were mixed in initialisation,
which doesn't quite work as intended.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
8 years ago*: add missing includes
David Lamparter [Tue, 3 Mar 2015 07:55:54 +0000 (08:55 +0100)]
*: add missing includes

Some places, particularly headers, were spewing warnings since they
don't include neccessary other headers to get struct/enum definitions.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 388f8857eb81ef75014060976776523a58a99389)

8 years ago*: fix signedness mix-ups
David Lamparter [Tue, 3 Mar 2015 07:55:26 +0000 (08:55 +0100)]
*: fix signedness mix-ups

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 21401f3215be26dcb0f787105f5907745498e966)

8 years agobgpd, lib, vtysh: hook up bgp VPNv6 CLI node
vivek [Tue, 7 Jun 2016 02:29:05 +0000 (19:29 -0700)]
bgpd, lib, vtysh: hook up bgp VPNv6 CLI node

Signed-off-by: Lou Berger <lberger@labn.net>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 13c378d96a57017f5995b2e0df46cfc31123f0e8)

Conflicts:
bgpd/bgp_vty.c
bgpd/bgpd.c
vtysh/vtysh_config.c