]>
git.ipfire.org Git - thirdparty/bird.git/log
Maria Matejka [Wed, 3 Jul 2019 09:09:52 +0000 (11:09 +0200)]
Merge branch 'master' into mq-filter-stack
Maria Matejka [Wed, 3 Jul 2019 06:44:42 +0000 (08:44 +0200)]
Merge branch 'mq-filter-stack' of gitlab.labs.nic.cz:labs/bird into mq-filter-stack
Maria Matejka [Wed, 3 Jul 2019 06:13:07 +0000 (08:13 +0200)]
Filter: CLI command to dump all the linearized filters
Maria Matejka [Tue, 2 Jul 2019 23:23:49 +0000 (01:23 +0200)]
Filter: Split printing and dying
Maria Matejka [Tue, 2 Jul 2019 22:04:24 +0000 (00:04 +0200)]
Removed obsolete comment at as_path_cut()
Maria Matejka [Tue, 2 Jul 2019 22:00:11 +0000 (00:00 +0200)]
Dynamic attributes definition split whether it is bitmask or not.
Maria Matejka [Tue, 2 Jul 2019 20:57:00 +0000 (22:57 +0200)]
Filter: Dropped some more irrelevant whitespace from generated files
Maria Matejka [Tue, 2 Jul 2019 15:59:21 +0000 (17:59 +0200)]
Filter: Nicer whitespaces in generated inst-gen.h
Maria Matejka [Tue, 2 Jul 2019 15:39:56 +0000 (17:39 +0200)]
Filter: documentation of the M4 preprocessor
Maria Matejka [Tue, 2 Jul 2019 11:13:29 +0000 (13:13 +0200)]
Filter: GCC, don't complain about indentation in generated code.
Maria Matejka [Tue, 2 Jul 2019 08:45:53 +0000 (10:45 +0200)]
Filter: Pre-evaluation of constant expressions
Maria Matejka [Mon, 1 Jul 2019 12:12:05 +0000 (14:12 +0200)]
Filter: Resolving of defined constants in config time
Maria Matejka [Mon, 1 Jul 2019 11:13:06 +0000 (13:13 +0200)]
Filter: Moved singleton member definitions to f-inst.c
Maria Matejka [Mon, 1 Jul 2019 10:49:02 +0000 (12:49 +0200)]
Filter: Moved f_inst allocation to separate function
Maria Matejka [Mon, 1 Jul 2019 10:07:06 +0000 (12:07 +0200)]
Filter: Getting rid of RESULT_OK. Adding RESULT_VOID.
This is a preparation for filter pre-evaluation.
Maria Matejka [Mon, 1 Jul 2019 09:57:35 +0000 (11:57 +0200)]
Filter: The interpreter code now shares its diversion with constructor
This is a preparation for filter pre-evaluation.
Maria Jan Matejka [Tue, 11 Jun 2019 13:19:21 +0000 (13:19 +0000)]
BGP: Prefix hash is too small, increase its max size.
This doesn't make any change for you until you have
millions of updates waiting to be sent. Increasing
the max hash size from 2^20 to 2^24.
Maria Jan Matejka [Tue, 11 Jun 2019 09:35:25 +0000 (09:35 +0000)]
BGP: split tx explicitly
If BGP has too many data to send and BIRD is slower than the link, TX is
always possible until all data is sent. This patch limits maximum number
of generated BGP messages in one iteration of TX hook.
Ondrej Zajicek (work) [Sun, 30 Jun 2019 20:30:56 +0000 (22:30 +0200)]
Add mock-up function for unit tests
They failed without it.
Ondrej Zajicek (work) [Sun, 30 Jun 2019 20:11:11 +0000 (22:11 +0200)]
Doc: OSPF graceful restart options
Ondrej Zajicek (work) [Sun, 30 Jun 2019 18:12:59 +0000 (20:12 +0200)]
OSPF: Support for graceful restart
Implement OSPFv2 (RFC 3623) and OSPFv3 (RFC 5187) graceful restart,
for both restarting and helper sides. Graceful restart is initiated
by 'graceful down' command.
Ondrej Zajicek (work) [Tue, 18 Jun 2019 14:27:21 +0000 (16:27 +0200)]
Nest: Add command to request graceful restart
When 'graceful down' command is entered, protocols are shut down
with regard to graceful restart. Namely Kernel protocol does
not remove routes and BGP protocol does not send notification,
just closes the connection.
Maria Matejka [Fri, 28 Jun 2019 09:08:48 +0000 (11:08 +0200)]
Filter: renaming pointers for consistency
The struct f_inst * is now always "what"
and the union member pointer is always "whati".
Maria Matejka [Thu, 27 Jun 2019 13:55:48 +0000 (15:55 +0200)]
Filter: A little cleanup of M4 interpreter generator
Maria Matejka [Tue, 25 Jun 2019 20:40:05 +0000 (22:40 +0200)]
Merge remote-tracking branch 'refs/remotes/origin/mq-filter-stack' into mq-filter-stack
Maria Matejka [Tue, 25 Jun 2019 14:18:06 +0000 (16:18 +0200)]
Conf/Filters: Moved argument count to conf scope
Maria Matejka [Fri, 21 Jun 2019 09:33:28 +0000 (11:33 +0200)]
Filter instructions don't confuse now v1 and res.
Maria Matejka [Wed, 19 Jun 2019 12:09:57 +0000 (14:09 +0200)]
Revert "Filter: Dropped the setter instructions in favor of direct result storage."
This reverts commit
bd91338246c1ba40358243f1bdf5a6dbd3a29f35 .
Maria Matejka [Thu, 13 Jun 2019 12:27:58 +0000 (14:27 +0200)]
String: bstrtoul macro expanded to bstrtoul10 and 16
Maria Matejka [Thu, 13 Jun 2019 12:24:48 +0000 (14:24 +0200)]
Filter: removal of semantically insane consts in filter_commit
Ondrej Zajicek (work) [Wed, 12 Jun 2019 16:02:01 +0000 (18:02 +0200)]
Add mock-up function for unit tests
They failed without it.
Ondrej Zajicek (work) [Wed, 12 Jun 2019 14:13:21 +0000 (16:13 +0200)]
Add CLI command to test reconfiguration status
Based on patch from Kenth Eriksson <kenth.eriksson@infinera.com>.
Kenth Eriksson [Wed, 12 Jun 2019 13:03:37 +0000 (15:03 +0200)]
BIRD coding conventions
Added Emacs config file describing BIRD coding conventions, as suggested
by Kenth Eriksson based on existing practice.
Ondrej Zajicek (work) [Wed, 12 Jun 2019 14:35:42 +0000 (16:35 +0200)]
BGP: Fix bug introduced in one of last patches
Maria Matejka [Fri, 31 May 2019 15:33:41 +0000 (17:33 +0200)]
Filter: Dropped the setter instructions in favor of direct result storage.
This should help filter performance a bit.
Maria Matejka [Thu, 30 May 2019 12:42:54 +0000 (14:42 +0200)]
Filter: Just a little comments in filter structure
Maria Matejka [Wed, 29 May 2019 19:03:52 +0000 (21:03 +0200)]
Filter: Stacks moved to thread-local storage if available.
Jan Maria Matejka [Thu, 23 May 2019 11:27:24 +0000 (11:27 +0000)]
Filters: If somebody doesn't like _Thread_local, don't fail for now, just be a little slower.
When the parallel execution comes into place, we'll likely enforce this
C11 feature. It's much simpler and also faster than pthread_[sg]etspecific().
Jan Maria Matejka [Wed, 22 May 2019 15:16:32 +0000 (15:16 +0000)]
Filter: Some people can't pronounce "postfixify" correctly. Let's try "linearize" instead.
This is just a naming change.
Jan Maria Matejka [Tue, 21 May 2019 16:33:37 +0000 (16:33 +0000)]
Filter: Store variables and function arguments on stack
Jan Maria Matejka [Mon, 20 May 2019 17:53:10 +0000 (17:53 +0000)]
Filter: Making the filter state thread local.
While having the filter code still reentrant if we really need,
the compiler can now do constant propagation and address the
thread local storage directly to save some computation time.
Maria Matejka [Fri, 17 May 2019 20:18:49 +0000 (22:18 +0200)]
Lexer now returns known sym / unknown sym / keyword
Ondrej Zajicek (work) [Tue, 30 Apr 2019 14:16:50 +0000 (16:16 +0200)]
Doc: Dynamic BGP
Alexander Azimov [Tue, 30 Apr 2019 11:55:43 +0000 (13:55 +0200)]
BGP: Compliance with RFC8203bis
Ondrej Zajicek (work) [Tue, 30 Apr 2019 11:44:11 +0000 (13:44 +0200)]
BGP: Output Local AS number in show protocol
Useful for implementation of agents implementing the SNMP-BGP MIB, which
requires the local AS of a session to be specified.
Thanks to Jan-Philipp Litza for the patch.
Ondrej Zajicek (work) [Mon, 8 Apr 2019 15:05:07 +0000 (17:05 +0200)]
BGP: Dynamic BGP
Support for dynamically spawning BGP protocols for incoming connections.
Use 'neighbor range' to specify range of valid neighbor addresses, then
incoming connections from these addresses spawn new BGP instances.
Ondrej Filip [Wed, 24 Apr 2019 11:49:18 +0000 (13:49 +0200)]
Small type in doc.
Ondrej Zajicek (work) [Fri, 12 Apr 2019 12:11:23 +0000 (14:11 +0200)]
OSPFv3: Fix some overlooked cases in IPv4 mode
Prefixes with max length (/32) were not handled properly.
Thanks to bauen1 for the bugreport.
Ondrej Zajicek (work) [Mon, 8 Apr 2019 14:39:22 +0000 (16:39 +0200)]
BGP: Handle corner cases in event ordering
When BGP connection is opened, it may happen that rx hook (with remote
OPEN) is called before tx hook (for local OPEN). Therefore, we need to do
internal changes (like setting local_caps) synchronously with OPENSENT
transition and we need to ensure that OPEN is sent before KEEPALIVE.
Ondrej Zajicek (work) [Wed, 3 Apr 2019 13:54:50 +0000 (15:54 +0200)]
BGP: Promiscuous ASN mode
Allow to specify just 'internal' or 'external' for remote neighbor
instead of specific ASN. In the second case that means BGP peers with
any non-local ASNs are accepted.
Ondrej Zajicek (work) [Tue, 2 Apr 2019 15:22:31 +0000 (17:22 +0200)]
BGP: Separate runtime and config usage of local/remote ip and as fields
Maria Matejka [Sat, 23 Mar 2019 12:32:14 +0000 (13:32 +0100)]
Filter: fixed error-checking bug in !~ operator
Maria Matejka [Fri, 22 Mar 2019 20:40:35 +0000 (21:40 +0100)]
Fixed one warning and one undefined value.
Maria Matejka [Wed, 20 Mar 2019 15:50:58 +0000 (16:50 +0100)]
Fixed an undefined symbol bug in CLI introduced by filter refactoring
Ondrej Zajicek (work) [Tue, 19 Mar 2019 18:38:32 +0000 (19:38 +0100)]
Doc: Route attribute cleanups
Ondrej Zajicek (work) [Tue, 19 Mar 2019 16:44:50 +0000 (17:44 +0100)]
BGP: Mandatory option for channels
Allow to mark channel to be mandatory, and do not allow BGP sessions if
no common AFI/SAFI is established.
Ondrej Zajicek (work) [Fri, 15 Mar 2019 19:54:01 +0000 (20:54 +0100)]
BGP: Handle case where capabilites are not used
If peer does not announce capabilities at all, or when we have
capabilities disabled, handle that as implicit IPv4 unicast.
Maria Matejka [Mon, 18 Mar 2019 11:54:40 +0000 (12:54 +0100)]
Merge branch 'master' into HEAD
Maria Matejka [Fri, 15 Mar 2019 14:07:00 +0000 (15:07 +0100)]
Build: Automatic dependency tracking for generated files
Maria Matejka [Thu, 7 Mar 2019 17:02:05 +0000 (18:02 +0100)]
Perf: fixed stupid allocation bug
Maria Matejka [Wed, 6 Mar 2019 20:45:28 +0000 (21:45 +0100)]
Gitlab CI: Drop CentOS 6 test build as unsupported.
If someone wants to maintain BIRD for CentOS 6,
feel free to send patches.
Ondrej Zajicek (work) [Thu, 14 Mar 2019 16:22:22 +0000 (17:22 +0100)]
Nest: Update handling of temporary attributes
The temporary atttributes are no longer removed by ea_do_prune(), but
they are undefined by store_tmp_attrs() protocol hooks. This fixes
several bugs where temporary attributes were removed when they should
not or not removed when they should be. The flag EAF_TEMP is no longer
needed and was removed.
Update all protocol make_tmp_attrs() / store_tmp_attrs() hooks to use
helper functions and to handle unset attributes properly.
Also fix some related bugs like improper handling of empty eattr list.
Ondrej Zajicek (work) [Wed, 6 Mar 2019 17:14:12 +0000 (18:14 +0100)]
OSPF: Improved handling of tmpattrs
Keep track of whether OSPF tmpattrs are actually defined for given route
(using flags in rte->pflags). That makes them behave more like real
eattrs so a protocol can define just a subset of them or they can be
undefined by filters.
Do not set ospf_metric2 for other than type 2 external OSPF routes and do
not set ospf_tag for non-external OSPF routes. That also fixes a bug
where internal/inter-area route propagated from one OSPF instance to
another is initiated with infinity ospf_metric2.
Thanks to Yaroslav Dronskii for the bugreport.
Maria Matejka [Wed, 6 Mar 2019 14:01:10 +0000 (15:01 +0100)]
Faster filters: documentation on what is happening there
Maria Matejka [Wed, 27 Feb 2019 13:40:05 +0000 (14:40 +0100)]
Fixed link time optimizer check for FreeBSD
Ondrej Zajicek (work) [Tue, 26 Feb 2019 17:19:35 +0000 (18:19 +0100)]
NEWS and version update
Maria Matejka [Tue, 26 Feb 2019 15:44:24 +0000 (16:44 +0100)]
Filters: comparison of functions and filters caching
Maria Matejka [Tue, 26 Feb 2019 15:11:40 +0000 (16:11 +0100)]
Build: No link time optimization when debug is enabled
Maria Matejka [Mon, 25 Feb 2019 22:28:36 +0000 (23:28 +0100)]
Custom number parser to speed up config parsing
The glibc's generic parser is slow due to its versatility. Specialized
parsers for base-10 and base-16 are much faster and we don't use other
bases.
Maria Matejka [Mon, 25 Feb 2019 16:19:47 +0000 (17:19 +0100)]
Conf: Lexer parses quoted strings in a more descriptive way
Maria Matejka [Fri, 22 Feb 2019 11:41:51 +0000 (12:41 +0100)]
Conf: Switch for faster (and slightly bigger) lexer
Maria Matejka [Fri, 22 Feb 2019 11:41:51 +0000 (12:41 +0100)]
Conf: Switch for faster (and slightly bigger) lexer
Ondrej Zajicek (work) [Fri, 22 Feb 2019 01:16:39 +0000 (02:16 +0100)]
Nest: Do not compare rte.flags during rte_update()
Route flags are mosty internal state of rtable, they are not significant
to whether a route has changed. With the old code, all routes received as
a part of enhanced route refresh are always re-announced to other peers
due to change in REF_STALE.
Maria Matejka [Wed, 20 Feb 2019 21:14:28 +0000 (22:14 +0100)]
Enabled link time optimization.
Maria Matejka [Tue, 19 Feb 2019 11:34:16 +0000 (12:34 +0100)]
Filter: Interpreter merged into the common m4 generator.
The config-time partial evaluation of constant expressions in filters is nearby.
Maria Matejka [Mon, 18 Feb 2019 13:57:15 +0000 (14:57 +0100)]
Filter: Fixed bugs in FI_CALL and FI_SWITCH
Maria Matejka [Mon, 18 Feb 2019 13:56:49 +0000 (14:56 +0100)]
Test: Added -d flag to die directly after first error.
Maria Matejka [Mon, 18 Feb 2019 13:56:10 +0000 (14:56 +0100)]
GDB: Added more pretty printers for filters
Maria Matejka [Fri, 15 Feb 2019 22:59:44 +0000 (23:59 +0100)]
Filter: More cleanup -- customized structures also in struct f_line_item
Maria Matejka [Fri, 15 Feb 2019 12:53:17 +0000 (13:53 +0100)]
Conf: Symbol implementation converted from void pointers to union
... and consted some declarations.
Maria Matejka [Wed, 13 Feb 2019 11:25:30 +0000 (12:25 +0100)]
Filter: merged filter compare functions into common M4 file
Maria Matejka [Tue, 12 Feb 2019 19:37:32 +0000 (20:37 +0100)]
Filter: Merged postfixify routine
Maria Matejka [Tue, 12 Feb 2019 13:16:28 +0000 (14:16 +0100)]
Filter: Merged filter line item dumpers into common generated source
Maria Matejka [Tue, 12 Feb 2019 10:35:41 +0000 (11:35 +0100)]
Filter: auto-generating enum-to-string
Maria Matejka [Tue, 12 Feb 2019 10:31:18 +0000 (11:31 +0100)]
Filter generator: workaround for M4 claiming all the put-around code be on one line
Maria Matejka [Mon, 11 Feb 2019 16:12:48 +0000 (17:12 +0100)]
Filter data manipulation functions separated to their file
Maria Matejka [Mon, 11 Feb 2019 15:44:14 +0000 (16:44 +0100)]
Filter: split the constructors to a separate file
Maria Matejka [Mon, 11 Feb 2019 14:27:47 +0000 (15:27 +0100)]
Conf: Fixed makefiles
Maria Matejka [Fri, 8 Feb 2019 12:38:12 +0000 (13:38 +0100)]
Filter: merged filter instruction constructors, counting line size on instruction construct
Maria Matejka [Fri, 8 Feb 2019 10:19:04 +0000 (11:19 +0100)]
Test: Fixed annoying warnings (and possible obscure bugs).
Maria Matejka [Thu, 7 Feb 2019 20:25:38 +0000 (21:25 +0100)]
Filters: split the large filter.h file to smaller files.
This should be revised, there are still ugly things in the filter API.
Maria Matejka [Wed, 6 Feb 2019 13:41:39 +0000 (14:41 +0100)]
Filter: M4 convertors polished a bit.
Maria Matejka [Wed, 30 Jan 2019 13:03:47 +0000 (14:03 +0100)]
Filter + Config: Fix bugs, tests and split symbols by type
Maria Matejka [Wed, 23 Jan 2019 16:08:27 +0000 (17:08 +0100)]
GDB pretty printers: f_inst and f_val.
Maria Matejka [Mon, 21 Jan 2019 08:17:54 +0000 (09:17 +0100)]
Filter: refactoring of instruction constructors
Maria Matejka [Thu, 27 Dec 2018 13:26:11 +0000 (14:26 +0100)]
Filter refactoring: dropped the recursion from the interpreter
This is a major change of how the filters are interpreted. If everything
works how it should, it should not affect you unless you are hacking the
filters themselves.
Anyway, this change should make a huge improvement in the filter performance
as previous benchmarks showed that our major problem lies in the
recursion itself.
There are also some changes in nest and protocols, related mostly to
spreading const declarations throughout the whole BIRD and also to
refactored dynamic attribute definitions. The need of these came up
during the whole work and it is too difficult to split out these
not-so-related changes.
Maria Matejka [Thu, 20 Dec 2018 15:25:54 +0000 (16:25 +0100)]
Filter refactoring: The instructions are converted to the switch body by M4
Maria Matejka [Thu, 20 Dec 2018 15:07:59 +0000 (16:07 +0100)]
Filter refactoring: Drop the roa check specific f_inst
Maria Matejka [Thu, 20 Dec 2018 14:25:04 +0000 (15:25 +0100)]
Filter refactoring: The constant f_val is simply included inside the instruction
With 32 bits, size of the args is 12 bytes, the f_val is 20 bytes.
With 64 bits, size of the args is 24 bytes, the f_val the same.
This is not so nice on 32 bits, anyway the f_inst itself is
24 vs. 32 bytes and the overall size of filters must be 32k of
instructions to get to one megabyte of RAM eaten by f_inst.
Therefore it seems to be improbable for common user to get into
problems with this change.
Maria Matejka [Thu, 20 Dec 2018 13:55:40 +0000 (14:55 +0100)]
Filter refactoring: Changed arguments from separate unions to an array