Commit graph

4 commits

Author SHA1 Message Date
Ryan Moeller
534e161747 libifconfig: Overhaul ifconfig_media_* interfaces
Define an ifmedia_t type to use for ifmedia words.

Add ifconfig_media_lookup_* functions to lookup ifmedia words by name.

Get media options as an array of option names rather than formatting it
as a comma-delimited list into a buffer.

Sprinkle const on static the static description tables for peace of
mind.

Don't need to zero memory allocated by calloc.

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

(cherry picked from commit c4ba4aa547)
2021-03-19 09:00:19 -04:00
Ryan Moeller
ca459d253f libifconfig: Add a function to get down reason
For use in ifconfig.

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

(cherry picked from commit b12a960e42)
2021-03-14 04:08:29 -04:00
Ryan Moeller
d63acd26f9 libifconfig: Fix typo in symbol map
(cherry picked from commit 80545a16df)
2021-03-14 04:06:30 -04:00
Mark Johnston
e3d06599bc libifconfig: Add a symbol map
This is a no-op for now since libifconfig is only built as a static lib.

Reviewed by:	freqlabs, kp, adrian
Differential Revision:	https://reviews.freebsd.org/D28119
2021-01-14 11:41:28 -05:00