wiphy: added accessor for the feature flags
This commit is contained in:
parent
367522fe8f
commit
933eabb6ef
|
@ -185,6 +185,11 @@ bool wiphy_can_connect(struct wiphy *wiphy, struct scan_bss *bss)
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool wiphy_has_feature(struct wiphy *wiphy, uint32_t feature)
|
||||||
|
{
|
||||||
|
return wiphy->feature_flags & feature;
|
||||||
|
}
|
||||||
|
|
||||||
bool wiphy_get_ext_feature(struct wiphy *wiphy, unsigned int idx)
|
bool wiphy_get_ext_feature(struct wiphy *wiphy, unsigned int idx)
|
||||||
{
|
{
|
||||||
return idx < sizeof(wiphy->ext_features) * 8 &&
|
return idx < sizeof(wiphy->ext_features) * 8 &&
|
||||||
|
|
|
@ -34,7 +34,8 @@ struct wiphy *wiphy_find(int wiphy_id);
|
||||||
const char *wiphy_get_path(struct wiphy *wiphy);
|
const char *wiphy_get_path(struct wiphy *wiphy);
|
||||||
uint32_t wiphy_get_supported_bands(struct wiphy *wiphy);
|
uint32_t wiphy_get_supported_bands(struct wiphy *wiphy);
|
||||||
bool wiphy_can_connect(struct wiphy *wiphy, struct scan_bss *bss);
|
bool wiphy_can_connect(struct wiphy *wiphy, struct scan_bss *bss);
|
||||||
bool wiphy_get_ext_feature(struct wiphy *wiphy, unsigned int idx);
|
bool wiphy_has_feature(struct wiphy *wiphy, uint32_t feature);
|
||||||
|
bool wiphy_has_ext_feature(struct wiphy *wiphy, unsigned int idx);
|
||||||
uint8_t wiphy_get_max_num_ssids_per_scan(struct wiphy *wiphy);
|
uint8_t wiphy_get_max_num_ssids_per_scan(struct wiphy *wiphy);
|
||||||
|
|
||||||
bool wiphy_init(struct l_genl_family *in, const char *whitelist,
|
bool wiphy_init(struct l_genl_family *in, const char *whitelist,
|
||||||
|
|
Loading…
Reference in New Issue