diff options
author | James Prestwood <james.prestwood@linux.intel.com> | 2018-10-17 21:33:06 +0200 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2018-11-09 11:33:40 +0100 |
commit | 99e3a44bac37ff033af711ec2ee8e48b6fabcad3 (patch) | |
tree | 4d728067b4f3e6aa780e849f9b442b07d90e2a69 /drivers/net/wireless/mac80211_hwsim.h | |
parent | mac80211_hwsim: move HWSIM_ATTR_RADIO_NAME parsing last (diff) | |
download | linux-99e3a44bac37ff033af711ec2ee8e48b6fabcad3.tar.xz linux-99e3a44bac37ff033af711ec2ee8e48b6fabcad3.zip |
mac80211_hwsim: allow setting iftype support
The mac80211_hwsim driver hard codes its supported interface types. For
testing purposes it would be valuable to allow changing these supported
types in order to simulate actual drivers than support a limited set of
iftypes. A new attribute was added to allow this:
- HWSIM_ATTR_IFTYPE_SUPPORT
A u32 bit field of supported NL80211_IFTYPE_* bits
This will only enable/disable iftypes that mac80211_hwsim already
supports.
In order to accomplish this, the ieee80211_iface_limit structure needed
to be built dynamically to only include limit rules for iftypes that
the user requested to enable.
Signed-off-by: James Prestwood <james.prestwood@linux.intel.com>
[fix some indentation, add netlink error string]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless/mac80211_hwsim.h')
-rw-r--r-- | drivers/net/wireless/mac80211_hwsim.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/mac80211_hwsim.h b/drivers/net/wireless/mac80211_hwsim.h index 0fe3199f8c72..3f6b670116d0 100644 --- a/drivers/net/wireless/mac80211_hwsim.h +++ b/drivers/net/wireless/mac80211_hwsim.h @@ -132,6 +132,7 @@ enum { * @HWSIM_ATTR_TX_INFO_FLAGS: additional flags for corresponding * rates of %HWSIM_ATTR_TX_INFO * @HWSIM_ATTR_PERM_ADDR: permanent mac address of new radio + * @HWSIM_ATTR_IFTYPE_SUPPORT: u32 attribute of supported interface types bits * @__HWSIM_ATTR_MAX: enum limit */ @@ -160,6 +161,7 @@ enum { HWSIM_ATTR_PAD, HWSIM_ATTR_TX_INFO_FLAGS, HWSIM_ATTR_PERM_ADDR, + HWSIM_ATTR_IFTYPE_SUPPORT, __HWSIM_ATTR_MAX, }; #define HWSIM_ATTR_MAX (__HWSIM_ATTR_MAX - 1) |