Search Linux Wireless

Re: [PATCH v4 1/6] nl80211/cfg80211: add radar detection command/event

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

 



On 16/10/2012 21:01, Johannes Berg wrote:
On Sun, 2012-10-14 at 16:48 +0200, Victor Goldenshtein wrote:

+ * @radar_detect_timeout: this timeout indicates the end of the channel
+ *	availability check for radar channels (in jiffies), only after this
+ *	period the user may initiate the tx on the channel.
+ * @cac_type: indicates that channel availability check is started for this
+ *	channel type.

You're missing docs for cac_started


missed that..

I'll fix it if I don't have any comments on the other patches and the
answer to my question below doesn't mean a change:

+++ b/net/wireless/nl80211.c
@@ -1411,6 +1411,7 @@ static int __nl80211_set_channel(struct cfg80211_registered_device *rdev,
  			result = -EINVAL;
  			break;
  		}
+		channel->cac_started = false;

Why this? If the device supports channel contexts then maybe one vif
could set the channel and the other could be doing radar detection? But
anyway this only presets the channel, so nothing will happen until the
AP interface is started? So basically I don't understand this at all.

Here we just clearing the cac_started flag, this was previously done in the ieee80211_do_stop() for the "sdata->wdev.preset_chan", but as we didn't want to modify cfg80211 fields from mac I suggested to move it here.

I"ll try to clarify things a bit, the channel availability check (CAC) could be started during:
1. AP init phase - when AP is configured on DFS channel.
2. As a result of a channel switch - AP moved to a DFS channel.

In both cases we set the cac_started flag from the nl80211_start_radar_detection() and clear it:
1. As a result of radar event.
2. In __nl80211_set_channel() - to cover the case when the CAC was initiated on a "preset_chan" (during AP init phase) and the IF was removed before the AP was even started (local->oper_channel wasn't set yet).


--
Thanks,
Victor.
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[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