K 10 svn:author V 2 kp K 8 svn:date V 27 2021-06-16T20:25:14.467406Z K 7 svn:log V 718 pf: Convenience function for optional (numeric) arguments Add _opt() variants for the uint* functions. These functions set the provided default value if the nvlist doesn't contain the relevant value. This is helpful for optional values (e.g. when the API is extended to add new fields). While here simplify the header by also using macros to create the prototypes for the macro-generated function implementations. Reviewed by: scottl MFC after: 2 weeks Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D30510 (cherry picked from commit 7c4342890bf17b72f0d79ada1326d9cbf34e736c) Git Hash: 9c84b01ac069ddf50dba58f2fcff965c525dc946 Git Author: kp@FreeBSD.org END