linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rajkumar Manoharan <rmanohar@codeaurora.org>
To: John Crispin <john@phrozen.org>
Cc: Johannes Berg <johannes@sipsolutions.net>,
	linux-wireless@vger.kernel.org, ath11k@lists.infradead.org
Subject: Re: [PATCH 3/3] ath11k: add support for BSS coloring
Date: Tue, 23 Jun 2020 14:53:53 -0700	[thread overview]
Message-ID: <9597d58917d651655e51ba313b69d0c4@codeaurora.org> (raw)
In-Reply-To: <20200617150021.4183253-3-john@phrozen.org>

On 2020-06-17 08:00, John Crispin wrote:
> Whenever the MAC detects a color collision or any of its associated 
> station
> detects one the FW will send out an event. Add the code to parse and 
> handle
> this event. and pass the data up to mac80211.
> 
> The FW does not provide an offload future such as the one used for CSA. 
> The
> CCA process is hence triggered via the beacon offload tx completion 
> events
> sent out by the FW.
> 
[...]
> +static void
> +ath11k_wmi_obss_color_collision_event(struct ath11k_base *ab, struct
> sk_buff *skb)
> +{
> +	const void **tb;
> +	const struct wmi_obss_color_collision_event *ev;
> +	struct ath11k_vif *arvif;
> +	int ret;
> +
> +	tb = ath11k_wmi_tlv_parse_alloc(ab, skb->data, skb->len, GFP_ATOMIC);
> +	if (IS_ERR(tb)) {
> +		ret = PTR_ERR(tb);
> +		ath11k_warn(ab, "failed to parse tlv: %d\n", ret);
> +		return;
> +	}
> +
> +	ev = tb[WMI_TAG_OBSS_COLOR_COLLISION_EVT];
> +	if (!ev) {
> +		ath11k_warn(ab, "failed to fetch obss color collision ev");
> +		goto exit;
> +	}
> +
> +	arvif = ath11k_mac_get_arvif_by_vdev_id(ab, ev->vdev_id);
> +	switch (ev->evt_type) {
> +	case WMI_BSS_COLOR_COLLISION_DETECTION:
> +		break;
> +	case WMI_BSS_COLOR_COLLISION_DISABLE:
> +	case WMI_BSS_COLOR_FREE_SLOT_TIMER_EXPIRY:
> +	case WMI_BSS_COLOR_FREE_SLOT_AVAILABLE:
> +		return;
> 
tb should be freed here.

-Rajkumar

      parent reply	other threads:[~2020-06-23 21:54 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-17 15:00 [PATCH 1/3] nl80211: add support for BSS coloring John Crispin
2020-06-17 15:00 ` [PATCH 2/3] mac80211: " John Crispin
2020-06-17 15:00 ` [PATCH 3/3] ath11k: " John Crispin
2020-06-22 14:45   ` Kalle Valo
2020-06-23 21:53   ` Rajkumar Manoharan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9597d58917d651655e51ba313b69d0c4@codeaurora.org \
    --to=rmanohar@codeaurora.org \
    --cc=ath11k@lists.infradead.org \
    --cc=johannes@sipsolutions.net \
    --cc=john@phrozen.org \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).