diff options
author | Andre Heider <a.heider@gmail.com> | 2022-11-21 17:27:20 +0100 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2022-12-16 00:09:07 +0100 |
commit | 87529770f6494189f3f21252c3a83d708f1faacf (patch) | |
tree | 3b2b75161be1399760358228a3c6c82dba941c92 /include | |
parent | 02f433e3052a5f2ee1c26c38a8beaf7a52fff645 (diff) | |
download | iwinfo-87529770f6494189f3f21252c3a83d708f1faacf.tar.gz |
utils: add and use iwinfo_format_hwmodes()
Unify how hwmodes are displayed, e.g.:
"802.11ac/ax/b/g/n" instead of "802.11bgnacax".
Luci currently uses a natural sort order, but that probably doesn't work
as intended once "be" is added, so let's do this here.
Signed-off-by: Andre Heider <a.heider@gmail.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/iwinfo/utils.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/iwinfo/utils.h b/include/iwinfo/utils.h index 1fa4f52..6fe5785 100644 --- a/include/iwinfo/utils.h +++ b/include/iwinfo/utils.h @@ -43,6 +43,8 @@ static inline int iwinfo_mbm2dbm(int gain) return gain / 100; } +size_t iwinfo_format_hwmodes(int modes, char *buf, size_t len); + int iwinfo_ifup(const char *ifname); int iwinfo_ifdown(const char *ifname); int iwinfo_ifmac(const char *ifname); |