Search Linux Wireless

Re: [RFC v2 1/5] nl80211: Add CONTROL_PORT_OVER_NL80211 attribute

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

 



On Wed, 2018-01-10 at 11:09 -0600, Denis Kenzior wrote:
> 
> +	WIPHY_FLAG_CONTROL_PORT_OVER_NL80211	= BIT(25),

I think it'd be easier for everyone to just use an nl80211 extended
feature flag for this, then you also don't need this code:

> +	if (info->attrs[NL80211_ATTR_CONTROL_PORT_OVER_NL80211]) {
> +		if (!info->attrs[NL80211_ATTR_SOCKET_OWNER])
> +			return -EINVAL;
> +
> +		if (!(rdev->wiphy.flags & WIPHY_FLAG_CONTROL_PORT_OVER_NL80211))
> +			return -EOPNOTSUPP;
> +
> +		settings->control_port_over_nl80211 = true;
> +	} else {
> +		settings->control_port_over_nl80211 = false;
> +	}

Nit: you don't really need the else branch.

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