Having metadata such as fibnum or vnet in the struct rib_head is handy as it eases building functionality in the routing space.
The first customer of this proposed change are route redirects.
More upcoming changes in the routing stack would benefit from having these fields.
Details
- Reviewers
bz ae - Group Reviewers
network - Commits
- rS356559: Add fibnum, family and vnet pointer to each rib head.
Diff Detail
- Repository
- rS FreeBSD src repository - subversion
- Lint
Lint Passed - Unit
No Test Coverage - Build Status
Buildable 28496 Build 26553: arc lint + arc unit
Event Timeline
Thank you so much for splitting this out. It really helps a lot! спасибо большой!
I assume this will not be MFCed due to KPI change?
sys/net/route.c | ||
---|---|---|
369 | Unrelated blank line. | |
sys/net/route_var.h | ||
51 | I think tableid could be misleading as it is not a unique ID; there might be multiple tables with the same ID. Maybe just calling it FIB is enough? |
Thank you for reviewing this!
I assume this will not be MFCed due to KPI change?
Well, actually I thought of MFC'ing the version which would keep dom_rtattach() and other functions the same, while filling in rib_family and rib_fibnum directly in the vnet_route_init() after call to the dom_rtattach().
Do you have any concerns about this?
sys/net/route_var.h | ||
---|---|---|
51 | Naming is hard :-) yep, will rename to fib number. |
The AF can be set in in6_inithead() already but I understand if you want to do all in the callers together; sounds like a good compromise for an MFC :-) Thanks!