From: Kalle Valo <kvalo@kernel.org>
To: Ping-Ke Shih <pkshih@realtek.com>
Cc: <tony0620emma@gmail.com>, <linux-wireless@vger.kernel.org>,
<phhuang@realtek.com>
Subject: Re: [PATCH] rtw88: 8822c: add ieee80211_ops::hw_scan
Date: Mon, 20 Dec 2021 21:03:12 +0200 [thread overview]
Message-ID: <87ilvj9k0f.fsf@codeaurora.org> (raw)
In-Reply-To: <20211217012908.9856-1-pkshih@realtek.com> (Ping-Ke Shih's message of "Fri, 17 Dec 2021 09:29:08 +0800")
Ping-Ke Shih <pkshih@realtek.com> writes:
> From: Po-Hao Huang <phhuang@realtek.com>
>
> Declare this function allows us to use customized scanning policy.
> By doing so we can be more time efficient on each scan. In order to
> make existing coex mechanism work as usual, firmware notifies driver
> on each channel switch event, then decide antenna ownership based on
> the current channel/band. Do note that this new mechanism affects
> throughput more than the sw_scan we used to have, but the overall
> average throughput is not affected since each scan take less time.
> Since the firmware size is limited, we only support probe requests
> with custom IEs length under 128 bytes for now, if any user space
> tools requires more than that, we'll introduce related changes
> afterwards. For backward compatibility, we fallback to sw_scan when
> using older firmware that does not support this feature.
>
> Signed-off-by: Po-Hao Huang <phhuang@realtek.com>
> Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
[...]
> +void rtw_hw_scan_start(struct rtw_dev *rtwdev, struct ieee80211_vif *vif,
> + struct ieee80211_scan_request *scan_req)
> +{
> + struct rtw_vif *rtwvif = (struct rtw_vif *)vif->drv_priv;
> + struct cfg80211_scan_request *req = &scan_req->req;
> + u8 mac_addr[ETH_ALEN];
> +
> + rtwdev->scan_info.scanning_vif = vif;
> + rtwvif->scan_ies = &scan_req->ies;
> + rtwvif->scan_req = req;
> + ieee80211_stop_queues(rtwdev->hw);
> + if (req->flags & NL80211_SCAN_FLAG_RANDOM_ADDR)
> + get_random_mask_addr(mac_addr, req->mac_addr,
> + req->mac_addr_mask);
> + else
> + ether_addr_copy(mac_addr, vif->addr);
> + rtw_core_scan_start(rtwdev, rtwvif, mac_addr, true);
> + rtwdev->hal.rcr &= ~BIT_CBSSID_BCN;
> + rtw_write32(rtwdev, REG_RCR, rtwdev->hal.rcr);
> +}
quite a few functions in this patch are not using empty lines which
makes it harder to read the code it's like trying to read english
without punctuation please use more empty lines and send v2 :)
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
prev parent reply other threads:[~2021-12-20 19:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-17 1:29 [PATCH] rtw88: 8822c: add ieee80211_ops::hw_scan Ping-Ke Shih
2021-12-20 19:03 ` Kalle Valo [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=87ilvj9k0f.fsf@codeaurora.org \
--to=kvalo@kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=phhuang@realtek.com \
--cc=pkshih@realtek.com \
--cc=tony0620emma@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.