From patchwork Sat Apr 15 20:31:55 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Larry Finger X-Patchwork-Id: 9682449 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 A031E60388 for ; Sat, 15 Apr 2017 20:32:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9368A2623D for ; Sat, 15 Apr 2017 20:32:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8885E26E48; Sat, 15 Apr 2017 20:32:23 +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=-4.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID, URIBL_BLACK 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 3C4BA262F2 for ; Sat, 15 Apr 2017 20:32:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754943AbdDOUcR (ORCPT ); Sat, 15 Apr 2017 16:32:17 -0400 Received: from mail-oi0-f67.google.com ([209.85.218.67]:36364 "EHLO mail-oi0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753886AbdDOUcO (ORCPT ); Sat, 15 Apr 2017 16:32:14 -0400 Received: by mail-oi0-f67.google.com with SMTP id b187so22210979oif.3 for ; Sat, 15 Apr 2017 13:32:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=r6/nrMlMOdkU9f7RmQ4BUQj7qsga9VPszhsDaLnfOyA=; b=L8z2/WC6S0URtpHO9dNfYenU5qNIg6jxApXZXXukMghgmz5BhG8GU3aIQTu+4k6wbq ArGjVmgpT5WY9o3eom2wU5D/hddvFDiPuqNajU6Lapq+kBfRFtm2EEPoFQT6uQChDeIe av0p1VLJIz0WQJTETvE+zzka0NtDV259M77i0kL/zMvyon6NMNNwaRgV2J47jXbNbdF5 5Q2FbnLhtjkmGIrPmh0puHWT+OJUxWY7nQX3ttVNdq6UMOLMSfgHnaqtzGgPS5cTFm5J bKDzxS4zDKnwOmGc7XMWRWIzDJjm9TWzMqrNoIk7WbxumSSntrTUuzlh3mfPTGWSLuJj I0FQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=r6/nrMlMOdkU9f7RmQ4BUQj7qsga9VPszhsDaLnfOyA=; b=L53QhmxxVabcVQkrmKYHwXXfOzPx9q0hGWhDoNCTcBCGDTFjTYiV07fVgUXOIdj7nI cellXGxlSG2AZ4CHrfi/jA0nZCWpxWzyc2rYgJIjy9A1teTwGS7OYkNg6fod+FYu/nzw pbn7iF4YtX1zx3n5/G47+PZJ9aybsWcuUGmDQqsp5xPn84dcA0C4kwMLzvinvu3uFNUX 5MXef8lIwh/Iax/+A9B37prhU/RHrsf8gc9FhGV8FdxZ77NYKPfOgqKQnNGYJQva097y dKBVQG1w7eeTUxklOSUKU5TE/A3fqN7zE/j3dixMzz2lriHUY7hv8scj/iFtkbcxyJ+q p+Ig== X-Gm-Message-State: AN3rC/6yMJ+rRNIycczvRo3SjMlY1utHGMPQwZeOzbIbdQ8KChVNE9Al r9FRxIiZtcesMQ== X-Received: by 10.202.169.150 with SMTP id s144mr1511764oie.85.1492288333984; Sat, 15 Apr 2017 13:32:13 -0700 (PDT) Received: from linux-4v1g.suse (cpe-24-31-249-175.kc.res.rr.com. [24.31.249.175]) by smtp.gmail.com with ESMTPSA id d38sm2551653otc.5.2017.04.15.13.32.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 15 Apr 2017 13:32:13 -0700 (PDT) From: Larry Finger To: kvalo@codeaurora.org Cc: linux-wireless@vger.kernel.org, Yan-Hsuan Chuang , Larry Finger , Pkshih , Birming Chiu , Shaofu , Steven Ting Subject: [PATCH 09/14] rtlwifi: btcoex: 21a 2ant: notify fw the number of APs Date: Sat, 15 Apr 2017 15:31:55 -0500 Message-Id: <20170415203200.22979-10-Larry.Finger@lwfinger.net> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170415203200.22979-1-Larry.Finger@lwfinger.net> References: <20170415203200.22979-1-Larry.Finger@lwfinger.net> 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 From: Yan-Hsuan Chuang Use h2c to tell the firmware if the number of AP is more than 10 or not. Signed-off-by: Yan-Hsuan Chuang Signed-off-by: Larry Finger Cc: Pkshih Cc: Birming Chiu Cc: Shaofu Cc: Steven Ting --- .../net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a2ant.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a2ant.c b/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a2ant.c index b93a4f7ce17a..9e152117730c 100644 --- a/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a2ant.c +++ b/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a2ant.c @@ -3982,6 +3982,7 @@ void ex_btc8821a2ant_media_status_notify(struct btc_coexist *btcoexist, u8 h2c_parameter[3] = {0}; u32 wifi_bw; u8 wifi_central_chnl; + u8 ap_num = 0; if (BTC_MEDIA_CONNECT == type) { RT_TRACE(rtlpriv, COMP_BT_COEXIST, DBG_LOUD, @@ -3999,10 +4000,15 @@ void ex_btc8821a2ant_media_status_notify(struct btc_coexist *btcoexist, h2c_parameter[0] = 0x1; h2c_parameter[1] = wifi_central_chnl; btcoexist->btc_get(btcoexist, BTC_GET_U4_WIFI_BW, &wifi_bw); - if (BTC_WIFI_BW_HT40 == wifi_bw) + if (wifi_bw == BTC_WIFI_BW_HT40) { h2c_parameter[2] = 0x30; - else + } else { h2c_parameter[2] = 0x20; + if (ap_num < 10) + h2c_parameter[2] = 0x30; + else + h2c_parameter[2] = 0x20; + } } coex_dm->wifi_chnl_info[0] = h2c_parameter[0];