summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-05-30Route destination field merged with nexthop attribute; splitting flowspec ↵Maria Matejka
validation result out. As there is either a nexthop or another destination specification (or othing in case of ROAs and Flowspec), it may be merged together. This code is somehow quirky and should be replaced in future by better implementation of nexthop. Also flowspec validation result has its own attribute now as it doesn't have anything to do with route nexthop.
2022-05-26Moved hostentry to eattrMaria Matejka
2022-05-26Moved nexthop from struct rta to extended attribute.Maria Matejka
This doesn't do anything more than to put the whole structure inside adata. The overall performance is certainly going downhill; we'll optimize this later. Anyway, this is one of the latest items inside rta and in several commits we may drop rta completely and move to eattrs-only routes.
2022-05-05All outstanding MPLS label stacks are stored as adataMaria Matejka
2022-05-04Moved route source attribute (RTS_*) to eattrsMaria Matejka
2022-05-04Removing the route scope attribute. Use custom attributes instead.Maria Matejka
The route scope attribute was used for simple user route marking. As there is a better tool for this (custom attributes), the old and limited way can be dropped.
2022-05-04Removed forgotten remnants of unused enum rtcMaria Matejka
2022-05-04Conf: Allowing keyword redefinitionMaria Matejka
Some tokens are both keywords and symbols. For now, we allow only specific keywords to be redefined; in future, more of the keywords may be added to this category. The redefinable keywords must be specified in any .Y file as follows: toksym: THE_KEYWORD ; See proto/bgp/config.Y for an example. Also dropped a lot of unused terminals.
2022-05-04Moved advertising router info (FROM attribute) to eattrsMaria Matejka
2022-05-04Moved route preference to eattrsMaria Matejka
2022-05-04Joined the RTA igp_metric and EA igp_metric attributesMaria Matejka
2022-05-04Explicit definition structures of route attributesMaria Matejka
Changes in internal API: * Every route attribute must be defined as struct ea_class somewhere. * Registration of route attributes known at startup must be done by ea_register_init() from protocol build functions. * Every attribute has now its symbol registered in a global symbol table defined as SYM_ATTRIBUTE * All attribute ID's are dynamically allocated. * Attribute value custom formatting hook is defined in the ea_class. * Attribute names are the same for display and filters, always prefixed by protocol name. Also added some unit testing code for filters with route attributes.
2022-05-04Conf: Symbols are properly scopedMaria Matejka
Now there is a persistent root symbol scope and all scopes have their symbol hashes to store local symbols and not leak any symbol out.
2022-05-04Replaced boilerplate eattr allocation by ea_set_attr()Maria Matejka
2022-05-04Enforcing certain data structure explicit paddings.Maria Matejka
Implicit paddings have undefined values in C. We want the eattr blocks to be comparable by memcmp and eattrs settable directly by structrure literals. This check ensures that all paddings in eattr and bval are explicit and therefore zeroed in all literals.
2022-05-04Protocols use EA_LITERAL_* to set attributesMaria Matejka
2022-05-04Local route attributes are always allocated from tmp_linpoolMaria Matejka
2022-05-04Filters always allocate from tmp_linpoolMaria Matejka
2022-05-04Attribute list normalization cleanupMaria Matejka
2022-05-04Moved filter value union to libMaria Matejka
2022-05-04Complex route attributes are data structures, shall be in lib alsoMaria Matejka
2022-05-04Splitting route data structures out to libMaria Matejka
2022-05-04FIB is a data structure generic enough to be in libMaria Matejka
2022-05-04Filters: removing adata_empty() duplicating lp_alloc_adata()Maria Matejka
2022-05-04Unified attribute and filter typesMaria Matejka
This commit removes the EAF_TYPE_* namespace completely and also for route attributes, filter-based types T_* are used. This simplifies fetching and setting route attributes from filters. Also, there is now union bval which serves as an universal value holder instead of private unions held separately by eattr and filter code.
2022-05-04Opaque types are named opaque also in filtersMaria Matejka
2022-05-04Special attribute types for enumsMaria Matejka
2022-05-04Dropping EAF_VAR_LENGTH as the attribute data is either embedded or adataMaria Matejka
2022-05-04Filter: Bitfield eattrs reading / writing moved to filter codeMaria Matejka
Before this change, fetch-update-write and bitmasking was hardcoded in attribute access code cased by the attribute type. Several filter instructions are used to do it instead. As this is certainly going to be a little bit slower than before, the switch block in attribute access code should be completely removed in near future, helping with both performance and code cleanliness. The user interface should have stayed intact.
2022-05-04Filter operations: bitwise AND and ORMaria Matejka
2022-05-04Implicit ROA check converted to explicit filter instruction sequenceMaria Matejka
2022-05-04Fixed spurious undef of route attributesAlexander Zubkov
2022-04-13RIP: fixed the EA_RIP_FROM attributeMaria Matejka
The interface pointer was improperly converted to u32 and back. Fixing this by explicitly allocating an adata structure for it. It's not so memory efficient, we'll optimize this later.
2022-04-06BGP uses lp_save / lp_restore instead of linpool flushingMaria Matejka
It is too cryptic to flush tmp_linpool in these cases and we don't want anybody in the future to break this code by adding an allocation somewhere which should persist over that flush. Saving and restoring linpool state is safer.
2022-04-06All linpools use pages to allocate regular blocksMaria Matejka
2022-04-06BGP: Fixed LLGR depreferencing in bgp_rte_mergableMaria Matejka
2022-04-06Protocols have their own explicit init routinesMaria Matejka
2022-04-06Unsetting route attributes without messing with type systemMaria Matejka
2022-04-06Eattr flags (originated and fresh) get their own struct fieldsMaria Matejka
2022-04-06Minor fix: f_val literals should always have named struct fieldsMaria Matejka
2022-04-06Converted Slab allocator to typed listsMaria Matejka
2022-04-06Slab allocator can free the blocks without knowing the parent structureMaria Matejka
2022-04-06Typed lists for easier walking and stronger type checkingMaria Matejka
2022-03-15Printf variant with a result allocated inside a pool / linpoolMaria Matejka
2022-03-14Slab memory allocator unit testMaria Matejka
2022-03-09Fixed a static assert in page allocatorMaria Matejka
2022-03-09Merge remote-tracking branch 'origin/master' into haugesundMaria Matejka
2022-03-09Merge commit '60880b539b8886f76961125d89a265c6e1112b7a' into haugesundMaria Matejka
2022-03-09BGP Flowspec validation: Removed in-route optimization for multithreading ↵Maria Matejka
compatibility
2022-03-09Merge commit 'e42eedb9' into haugesundMaria Matejka