HomeFreeBSD

netlink: refactor KPI for generic Netlink modules

Description

netlink: refactor KPI for generic Netlink modules

Now that the family and group are completely private to netlink_generic.c,
provide a simple and robust KPI, that would require very simple guarantees
from both KPI and the module:

  • Strings are used only for family and group registration, that return ID: uint16_t genl_register_family(const char *name, ... uint32_t genl_register_group(uint16_t family, const char *name, ...
  • Once created families and groups are guaranteed to not disappear and be addressable by their ID.
  • All subsequent calls, including deregistration shall use ID.

Reviewed by: kp
Differential Revision: https://reviews.freebsd.org/D48845

Details

Provenance
glebiusAuthored on Wed, Feb 5, 6:09 PM
Reviewer
kp
Differential Revision
D48845: netlink: refactor KPI for generic Netlink modules
Parents
rG194bb58b80c1: x86: Fixes for nmi/pmi interrupt sharing
Branches
Unknown
Tags
Unknown