From patchwork Tue Feb 13 09:50:48 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arend van Spriel X-Patchwork-Id: 10215633 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B0B43601C2 for ; Tue, 13 Feb 2018 09:51:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9DB7428E81 for ; Tue, 13 Feb 2018 09:51:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9BCA328E7F; Tue, 13 Feb 2018 09:51:05 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4748C28E8E for ; Tue, 13 Feb 2018 09:51:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934945AbeBMJuz (ORCPT ); Tue, 13 Feb 2018 04:50:55 -0500 Received: from mail-qt0-f171.google.com ([209.85.216.171]:46809 "EHLO mail-qt0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934268AbeBMJuv (ORCPT ); Tue, 13 Feb 2018 04:50:51 -0500 Received: by mail-qt0-f171.google.com with SMTP id u6so2941484qtg.13 for ; Tue, 13 Feb 2018 01:50:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=xNAFRDPPsYV53EXaNCUw8H64H92VRdxcIH1LpoP6O40=; b=SbQo7BRSD6Yi6wGuVl60jHw7LAEcQDUCf/DY8J4W+BOv27xTh+pRHZqaf2V5F+fV0B JK/zucPhSPO4/3D9QX4EBP2MtoQbN8R1L9e1+x9eotZAZE8MJ2fAGZNP731oeF06eQAp h2DUyI3PNb/jlsONHUdajSGlVVZ97QgIbRUKU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=xNAFRDPPsYV53EXaNCUw8H64H92VRdxcIH1LpoP6O40=; b=qv7C0xNRAFvQ2geMFJDc3yxl+8sKCUpk9IOVDcVaeJCBZYzyhORQbZ0qZgxRm78eCN XpnY02VB9rHHSV0pAUEjHxBvlVWNC855KHvW9SgYo8cQoSPSdvakTyDRnUmnsfLb3OgU EWgsAbnOPMJNiUUM4irD7sCfL8n1PpEa2OgGAPRp+SvIz9gDaQNOa83ptue0x2gc3NoM e3ULpSAq3DXI72h9lFZdF/5nYDbyrNY7JlN1OXLHk0ijkSxLq3tXRwmNk7p9p4plAEYg dReen5r1bXIo8N9zjU3Qj/GzKGSQD7fYElKMyxasi39HHNuhGCSLZlw8A5NLliUzlbdX 0pRA== X-Gm-Message-State: APf1xPB9C/+amlncoUe9/pF0zQpJE5CWKxumOev25Q4jCFp/DvRi6GeU zjyAH4RRFVPQpQ9PT3I/r7h1h3sF7Bw= X-Google-Smtp-Source: AH8x22752rOumB52NNsO+/X7+xvjqyj/pM3Ob99uRk+k/TITOi87zWiujJe+S97keOjaF4peR/A/aA== X-Received: by 10.200.39.173 with SMTP id w42mr976203qtw.206.1518515450630; Tue, 13 Feb 2018 01:50:50 -0800 (PST) Received: from [10.176.68.125] ([192.19.248.250]) by smtp.gmail.com with ESMTPSA id l41sm8045493qtc.22.2018.02.13.01.50.48 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 13 Feb 2018 01:50:50 -0800 (PST) Subject: Re: Make brcmfmac repeat authentication requests To: Daniel Drake , franky.lin@broadcom.com, hante.meuleman@broadcom.com, chi-hsien.lin@cypress.com, wright.feng@cypress.com References: Cc: linux-wireless@vger.kernel.org, brcm80211-dev-list.pdl@broadcom.com, brcm80211-dev-list@cypress.com, Linux Upstreaming Team From: Arend van Spriel Message-ID: <5A82B4F8.2090209@broadcom.com> Date: Tue, 13 Feb 2018 10:50:48 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On 2/12/2018 3:04 PM, Daniel Drake wrote: > Hi, > > We are working with the Weibu F3C MiniPC which includes BCM43455 SDIO > wifi chip 0x004345(17221) rev 0x000006 > > Testing Linux 4.15, this wifi adapter is unable to authenticate with > the MF928 MiFi Access Point which is common in Africa. The STA sends > the authentication request, which is ACKed by the AP, but then the > conversation ends there (a timeout later bubbles up to userspace). > Windows 10 with broadcom driver version 1.605.1.0 is also unable to > connect. I tried to find info about that access point equipment, but not getting any hits apart from a olivetti laser printer, but I doubt it is that. Can you provide more details. > My laptop with ath10k can authenticate and connect fine. There the > conversation is: > > 1. STA sends authentication request > 2. AP sends ACK > 3. After 0.1s timeout, STA sends another auth request > 4. AP sends ACK > 5. AP sends authentication response > 6. etc. > > Also confirmed the same pattern on a couple of smartphones, where the > delay seems to be 0.3s before repeating the authentication request. > > Clearly this AP is not behaving correctly; the authentication request > should not have to be repeated. However of all the devices to hand, > unfortunately only this broadcom device is unable to connect. User-space (wpa_supplicant) would retry the connect attempt so I guess you are saying that the timing between the two auth requests is important? > Is there a way to adjust the driver/firmware to repeat the > authentication requests when they are not responded to? This would > match the behaviour of other devices and work around this issue. Is firmware not repeating at all or is the time between the two auth requests too long? Checking firmware there is a 300ms timeout and it does a retry if the limit is not reached. However, that limit is initialized to zero :-p Could you try the patch below? Regards, Arend > Thanks > Daniel > diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c b/drivers index 19686ef..af1ab00 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c @@ -384,6 +384,9 @@ int brcmf_c_preinit_dcmds(struct brcmf_if *ifp) goto done; } + /* allow join retry by firmware */ + (void)brcmf_fil_iovar_int_set(ifp, "assoc_retry_max", 1); + /* Enable tx beamforming, errors can be ignored (not supported) */ (void)brcmf_fil_iovar_int_set(ifp, "txbf", 1);