Search Linux Wireless

Re: [PATCH v3 2/6] wifi: mac80211: validate and configure puncturing bitmap in start_ap()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 2023-01-29 at 23:22 -0800, Aloka Dixit wrote:
> - Make puncturing bitmap 32 bit to match NL80211 interface.
> - Export ieee80211_valid_disable_subchannel_bitmap() and use it to
> validate the puncturing bitmap in AP mode.
> - Modify 'change' in ieee80211_start_ap() from u32 to u64 to support
> BSS_CHANGED_EHT_PUNCTURING.
> - Configure the bitmap in link_conf and notify the driver.
> 
> Signed-off-by: Aloka Dixit <quic_alokad@xxxxxxxxxxx>
> Signed-off-by: Muna Sinada <quic_msinada@xxxxxxxxxxx>
> ---
> v3: This patch depends on following,
> https://patchwork.kernel.org/project/linux-wireless/patch/20230127123930.4fbc74582331.I3547481d49f958389f59dfeba3fcc75e72b0aa6e@changeid/
> 
>  include/net/mac80211.h     |  2 +-
>  net/mac80211/cfg.c         | 10 +++++++++-
>  net/mac80211/ieee80211_i.h |  2 ++
>  net/mac80211/mlme.c        | 10 +++++-----
>  4 files changed, 17 insertions(+), 7 deletions(-)
> 
> diff --git a/include/net/mac80211.h b/include/net/mac80211.h
> index 54ffc0cc2918..b1c17c7ac044 100644
> --- a/include/net/mac80211.h
> +++ b/include/net/mac80211.h
> @@ -738,7 +738,7 @@ struct ieee80211_bss_conf {
>  	u8 tx_pwr_env_num;
>  	u8 pwr_reduction;
>  	bool eht_support;
> -	u16 eht_puncturing;
> +	u32 eht_puncturing;

Don't see a reason to change this right now.

> @@ -1296,6 +1296,14 @@ static int ieee80211_start_ap(struct wiphy *wiphy, struct net_device *dev,
>  				IEEE80211_HE_PHY_CAP2_UL_MU_FULL_MU_MIMO;
>  	}
>  
> +	if (params->eht_cap) {
> +		if (!ieee80211_valid_disable_subchannel_bitmap(
> +							&params->punct_bitmap,
> +							params->chandef.width))
> +			return -EINVAL;
> +		link_conf->eht_puncturing = params->punct_bitmap;
> +		changed |= BSS_CHANGED_EHT_PUNCTURING;
> +	}
>  	if (sdata->vif.type == NL80211_IFTYPE_AP &&

An extra blank line wouldn't be bad :)

And some other bits of this would change by moving the validation to
cfg80211, of course.

Might even be worth doing that as a completely separate patch 1/7?

johannes




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux