FST: Make fst_hw_mode_to_band() non-inline function
There is no need for using an inline function for this. Save a bit in binary size by using a normal function. Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
78ca254237
commit
8f997f044f
2 changed files with 18 additions and 16 deletions
|
@ -206,3 +206,20 @@ Boolean fst_are_ifaces_aggregated(struct fst_iface *iface1,
|
||||||
{
|
{
|
||||||
return fst_iface_get_group(iface1) == fst_iface_get_group(iface2);
|
return fst_iface_get_group(iface1) == fst_iface_get_group(iface2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
enum mb_band_id fst_hw_mode_to_band(enum hostapd_hw_mode mode)
|
||||||
|
{
|
||||||
|
switch (mode) {
|
||||||
|
case HOSTAPD_MODE_IEEE80211B:
|
||||||
|
case HOSTAPD_MODE_IEEE80211G:
|
||||||
|
return MB_BAND_ID_WIFI_2_4GHZ;
|
||||||
|
case HOSTAPD_MODE_IEEE80211A:
|
||||||
|
return MB_BAND_ID_WIFI_5GHZ;
|
||||||
|
case HOSTAPD_MODE_IEEE80211AD:
|
||||||
|
return MB_BAND_ID_WIFI_60GHZ;
|
||||||
|
default:
|
||||||
|
WPA_ASSERT(0);
|
||||||
|
return MB_BAND_ID_WIFI_2_4GHZ;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -28,22 +28,7 @@
|
||||||
fst_printf_group(fst_iface_get_group(iface), (level), "%s: " format, \
|
fst_printf_group(fst_iface_get_group(iface), (level), "%s: " format, \
|
||||||
fst_iface_get_name(iface), ##__VA_ARGS__)
|
fst_iface_get_name(iface), ##__VA_ARGS__)
|
||||||
|
|
||||||
static inline enum mb_band_id
|
enum mb_band_id fst_hw_mode_to_band(enum hostapd_hw_mode mode);
|
||||||
fst_hw_mode_to_band(enum hostapd_hw_mode mode)
|
|
||||||
{
|
|
||||||
switch (mode) {
|
|
||||||
case HOSTAPD_MODE_IEEE80211B:
|
|
||||||
case HOSTAPD_MODE_IEEE80211G:
|
|
||||||
return MB_BAND_ID_WIFI_2_4GHZ;
|
|
||||||
case HOSTAPD_MODE_IEEE80211A:
|
|
||||||
return MB_BAND_ID_WIFI_5GHZ;
|
|
||||||
case HOSTAPD_MODE_IEEE80211AD:
|
|
||||||
return MB_BAND_ID_WIFI_60GHZ;
|
|
||||||
default:
|
|
||||||
WPA_ASSERT(0);
|
|
||||||
return MB_BAND_ID_WIFI_2_4GHZ;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
struct fst_ctrl_handle {
|
struct fst_ctrl_handle {
|
||||||
struct fst_ctrl ctrl;
|
struct fst_ctrl ctrl;
|
||||||
|
|
Loading…
Reference in a new issue