Search Linux Wireless

Re: [PATCH 03/10] qtnfmac: add support for radar detection and CAC

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

 



Kalle Valo <kvalo@xxxxxxxxxxxxxx> writes:

> Sergey Matyukevich <sergey.matyukevich.os@xxxxxxxxxxxxx> writes:
>
>> From: Igor Mitsyanko <igor.mitsyanko.os@xxxxxxxxxxxxx>
>>
>> Implement two parts of radar handling logic:
>> - cfg80211 .start_radar_detect callback to allow nl80211 to initiate CAC
>> - radar event to allow wlan device to advertize CAC and radar events
>>
>> Signed-off-by: Igor Mitsyanko <igor.mitsyanko.os@xxxxxxxxxxxxx>
>
> [...]
>
>> +int qtnf_cmd_start_cac(const struct qtnf_vif *vif,
>> +		       const struct cfg80211_chan_def *chdef,
>> +		       u32 cac_time_ms)
>> +{
>> +	struct qtnf_bus *bus = vif->mac->bus;
>> +	struct sk_buff *cmd_skb;
>> +	struct qlink_cmd_start_cac *cmd;
>> +	int ret;
>> +	u16 res_code;
>> +
>> +	cmd_skb = qtnf_cmd_alloc_new_cmdskb(vif->mac->macid, vif->vifid,
>> +					    QLINK_CMD_START_CAC,
>> +					    sizeof(*cmd));
>> +	if (unlikely(!cmd_skb))
>> +		return -ENOMEM;
>
> The unlikely() looks pretty useless here. likely() and unlikely() are
> supposed to be used in cases where it matters and the improvment can be
> measured, I doubt that's the case here.

But no need to resend just because of this.

-- 
Kalle Valo



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

  Powered by Linux