Search Linux Wireless

Re: [PATCH v4 04/11] wifi: cfg80211: report per wiphy radio antenna mask

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

 



On Tue, 2024-10-08 at 09:23 +0200, Felix Fietkau wrote:
> 
> +++ b/net/wireless/nl80211.c
> @@ -2428,7 +2428,9 @@ static int nl80211_put_radio(struct wiphy *wiphy, struct sk_buff *msg, int idx)
>  	if (!radio)
>  		return -ENOBUFS;
>  
> -	if (nla_put_u32(msg, NL80211_WIPHY_RADIO_ATTR_INDEX, idx))
> +	if (nla_put_u32(msg, NL80211_WIPHY_RADIO_ATTR_INDEX, idx) ||
> +	    nla_put_u32(msg, NL80211_WIPHY_RADIO_ATTR_ANTENNA_MASK,
> +			r->antenna_mask))
>  		goto nla_put_failure;
> 

This should probably not be reported if it's 0, because that's nonsense
and just means the driver didn't provide the info.

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