mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-22 23:04:43 +00:00
mac80211: allow changing TX-related netdev features
Set ndev->hw_features as well as ndev->features to allow changing the TX-related features with ethtool. We cannot (yet) change RX-related features since that requires telling the driver about it and we have no API for that yet. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Link: https://lore.kernel.org/r/20200131111300.891737-10-luca@coelho.fi Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
b5db1acab1
commit
07b83d2ecd
3 changed files with 11 additions and 6 deletions
|
@ -872,7 +872,6 @@ int ieee80211_register_hw(struct ieee80211_hw *hw)
|
|||
enum nl80211_band band;
|
||||
int channels, max_bitrates;
|
||||
bool supp_ht, supp_vht, supp_he;
|
||||
netdev_features_t feature_whitelist;
|
||||
struct cfg80211_chan_def dflt_chandef = {};
|
||||
|
||||
if (ieee80211_hw_check(hw, QUEUE_CONTROL) &&
|
||||
|
@ -931,10 +930,7 @@ int ieee80211_register_hw(struct ieee80211_hw *hw)
|
|||
}
|
||||
|
||||
/* Only HW csum features are currently compatible with mac80211 */
|
||||
feature_whitelist = NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
|
||||
NETIF_F_HW_CSUM | NETIF_F_SG | NETIF_F_HIGHDMA |
|
||||
NETIF_F_GSO_SOFTWARE | NETIF_F_RXCSUM;
|
||||
if (WARN_ON(hw->netdev_features & ~feature_whitelist))
|
||||
if (WARN_ON(hw->netdev_features & ~MAC80211_SUPPORTED_FEATURES))
|
||||
return -EINVAL;
|
||||
|
||||
if (hw->max_report_rates == 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue