mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-12-22 12:42:51 +01:00
band: add band_chandef_width_to_string
This commit is contained in:
parent
9e01563e8c
commit
28f5297b78
20
src/band.c
20
src/band.c
@ -1422,3 +1422,23 @@ enum band_freq band_oper_class_to_band(const uint8_t *country,
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
|
||||
const char *band_chandef_width_to_string(enum band_chandef_width width)
|
||||
{
|
||||
switch (width) {
|
||||
case BAND_CHANDEF_WIDTH_20NOHT:
|
||||
return "20MHz (no-HT)";
|
||||
case BAND_CHANDEF_WIDTH_20:
|
||||
return "20MHz";
|
||||
case BAND_CHANDEF_WIDTH_40:
|
||||
return "40MHz";
|
||||
case BAND_CHANDEF_WIDTH_80:
|
||||
return "80MHz";
|
||||
case BAND_CHANDEF_WIDTH_80P80:
|
||||
return "80+80MHz";
|
||||
case BAND_CHANDEF_WIDTH_160:
|
||||
return "160MHz";
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
@ -111,3 +111,4 @@ uint8_t band_freq_to_channel(uint32_t freq, enum band_freq *out_band);
|
||||
uint32_t band_channel_to_freq(uint8_t channel, enum band_freq band);
|
||||
enum band_freq band_oper_class_to_band(const uint8_t *country,
|
||||
uint8_t oper_class);
|
||||
const char *band_chandef_width_to_string(enum band_chandef_width width);
|
||||
|
Loading…
Reference in New Issue
Block a user