From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail-yb0-x241.google.com ([2607:f8b0:4002:c09::241]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1f8Lsh-0003ya-TL for ath10k@lists.infradead.org; Tue, 17 Apr 2018 08:22:30 +0000 Received: by mail-yb0-x241.google.com with SMTP id t8-v6so8051226ybo.9 for ; Tue, 17 Apr 2018 01:22:17 -0700 (PDT) Subject: Re: [PATCH 2/2] ath10k: support MAC address randomization in scan References: <1522379640-6442-1-git-send-email-cjhuang@codeaurora.org> <1522379640-6442-3-git-send-email-cjhuang@codeaurora.org> <20180412205954.GA34456@rodete-desktop-imager.corp.google.com> <877epbs5v7.fsf@kamboji.qca.qualcomm.com> <5AD11D7C.1030603@broadcom.com> <242be71eb87140c9560163c4000255b2@codeaurora.org> <8736zvqtcw.fsf@kamboji.qca.qualcomm.com> <20180417002854.GA186697@rodete-desktop-imager.corp.google.com> From: Arend van Spriel Message-ID: <5AD5AEB5.1040808@broadcom.com> Date: Tue, 17 Apr 2018 10:22:13 +0200 MIME-Version: 1.0 In-Reply-To: <20180417002854.GA186697@rodete-desktop-imager.corp.google.com> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "ath10k" Errors-To: ath10k-bounces+kvalo=adurom.com@lists.infradead.org To: Brian Norris , Kalle Valo Cc: cjhuang@codeaurora.org, linux-wireless@vger.kernel.org, ath10k@lists.infradead.org On 4/17/2018 2:28 AM, Brian Norris wrote: > Hi, > > On Mon, Apr 16, 2018 at 02:32:47PM +0300, Kalle Valo wrote: >> cjhuang@codeaurora.org writes: >>> On 2018-04-14 05:13, Arend van Spriel wrote: >>>> On 4/13/2018 1:28 PM, Kalle Valo wrote: >>>>> cjhuang@codeaurora.org writes: >>>>> >>>>>>>> + if (test_bit(WMI_SERVICE_SPOOF_MAC_SUPPORT, ar->wmi.svc_map)) { >>>>>>>> + ret = ath10k_wmi_scan_prob_req_oui(ar, ar->mac_addr); >>>>>>>> + if (ret) { >>>>>>>> + ath10k_err(ar, "failed to set prob req oui: %i\n", ret); >>>>>>>> + goto err_dfs_detector_exit; >>>>>>>> + } >>>>>>>> + >>>>>>>> + ar->hw->wiphy->features |= >>>>>>>> + NL80211_FEATURE_SCAN_RANDOM_MAC_ADDR; >>>>>>> >>>>>>> Do you support NL80211_FEATURE_SCHED_SCAN_RANDOM_MAC_ADDR too? >>>>>> >>>>>> I'll add this flag too. >>>>> >>>>> Are you going to send v2 or what's the plan? >>>> >>>> Maybe a stupid question, but does ath10k support scheduled scan? > > Not a stupid question. Sorry for not asking that first. > >> AFAICS ath10k does not support it (sched_scan_start() op). > > Right, that seems to be the case. > >>> The reason is AVL test case needs this flag to enable random mac >>> address scan. Maybe Brian Can explain why this flag is necessary. > > I never actually claimed you *needed* this flag; I just wondered how you > claimed to pass our test when you did not support this flag, since our > network manager currently checks for both > NL80211_FEATURE_SCAN_RANDOM_MAC_ADDR and > NL80211_FEATURE_SCHED_SCAN_RANDOM_MAC_ADDR before enabling MAC > randomization in scans. But that's no matter to worry about here. > >> If ath10k does not support scheduled scan what's the point? Shouldn't >> the test case then be it fixed instead of making hacks in ath10k? > > Indeed. We're trying to work that out right now. > > It looks like the status quo for looking for SCHED_SCAN support is to > check if NL80211_CMD_START_SCHED_SCAN shows up in the command support > list. (IOW, that's what wpa_supplicant does.) We'll probably need to > imitate that. I believe checking command support is not really recommended. Instead, you better check NL80211_ATTR_SCHED_SCAN_MAX_REQS being non-zero (since kernel 4.12 that is). Regards, Arend _______________________________________________ ath10k mailing list ath10k@lists.infradead.org http://lists.infradead.org/mailman/listinfo/ath10k