From patchwork Mon May 4 06:07:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wright Feng X-Patchwork-Id: 11525053 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6E56C1862 for ; Mon, 4 May 2020 06:09:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 55E62206D9 for ; Mon, 4 May 2020 06:09:14 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=cypress.com header.i=@cypress.com header.b="KWPtJzzY" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726578AbgEDGJD (ORCPT ); Mon, 4 May 2020 02:09:03 -0400 Received: from mail-bn8nam12on2092.outbound.protection.outlook.com ([40.107.237.92]:14944 "EHLO NAM12-BN8-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726410AbgEDGJC (ORCPT ); Mon, 4 May 2020 02:09:02 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UwMoRXgIEWbsBe9hxbHiRCRLvZu3zlLXXy+hnCKEdwjTxR9nPWQvF65d2Hpba099j+7ZL32QvSgjcEakZwbtr5rx57oN+IdBZxq8V84heHJm2URZ4F+AG027S/m8/jyyaujOSCBDGeZ6aFHUTqXdkjXhJ/pcG5RXTfoBiXvUHsoOL4TpRjay8PCasJSp3Qdv00AMEHRd1wUx5yGq8hbSoxJBKC47kqgIWjz8kioT01jCdWvpIJY3DkQrndm4YTeE/MConjKfpcuPmA+8RqFMJbwKbAcG6Iw9CUvEDQLVPRkMKdTfuJdMSz7IOZahcpcVV/H+cEhEOnjb9GzagERUIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xt7FX1Grz18H29crfJNZ5W6boKUb/aV+ztGherQr3D8=; b=N0xu00o0rstwNOQTknj+EupxY8+4kcB8qVKfSIsQeXLXr894gWp/l+uusXD+zaRe93OZumikRVBIuSthB909GF3dqHiWzFlrudITrtvMWWM1/EHK32TYYq7LdafxXuTFcVt5THxmG6pGYyuaSWjc39EW3OnSUN0Dhr/B2tiEYn468+rMXVg4tWAx2qgFE1606ZaDk0HDHSLZjMdfr0uaNpS6ZdAqKkRwb8Kq7wzZP9s83AoPj+MvLZbIDEbqOF1kPVLmcmhmASbgwH0pCn8nFmQUzBYtmbLAyfqKm2rSeJzjn144eywK8WvkAg/i8sO2Xpdf6RxulSxB7nxpj9ab7w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=cypress.com; dmarc=pass action=none header.from=cypress.com; dkim=pass header.d=cypress.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cypress.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xt7FX1Grz18H29crfJNZ5W6boKUb/aV+ztGherQr3D8=; b=KWPtJzzYwADm0jMEAsFeI9ZPHvFZv+dwv0BJIHEcLlkka/qoOVW0w7SBrE80GeDpBOKp5Be/XqUn7rIgtPCkyKeS50m2dn07TbKSJOPqrYRKp16X30ZDqkrgdMvBdIqqhTsYxfG8Bh+Uz3soX4qIyjtpRoKg/YK7DJSvx/HwafE= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=cypress.com; Received: from DM6PR06MB4748.namprd06.prod.outlook.com (2603:10b6:5:fd::18) by DM6PR06MB4283.namprd06.prod.outlook.com (2603:10b6:5:1e::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.29; Mon, 4 May 2020 06:09:00 +0000 Received: from DM6PR06MB4748.namprd06.prod.outlook.com ([fe80::ad0b:eda4:4eb8:b8d7]) by DM6PR06MB4748.namprd06.prod.outlook.com ([fe80::ad0b:eda4:4eb8:b8d7%7]) with mapi id 15.20.2958.027; Mon, 4 May 2020 06:09:00 +0000 From: Wright Feng To: linux-wireless@vger.kernel.org, chi-hsien.lin@cypress.com Cc: wright.feng@cypress.com, brcm80211-dev-list@broadcom.com, brcm80211-dev-list@cypress.com, Arend van Spriel , Franky Lin , Hante Meuleman , Kalle Valo Subject: [PATCH 1/3] brcmfmac: support the second p2p connection Date: Mon, 4 May 2020 01:07:31 -0500 Message-Id: <1588572453-194663-2-git-send-email-wright.feng@cypress.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1588572453-194663-1-git-send-email-wright.feng@cypress.com> References: <1588572453-194663-1-git-send-email-wright.feng@cypress.com> X-ClientProxiedBy: MN2PR01CA0061.prod.exchangelabs.com (2603:10b6:208:23f::30) To DM6PR06MB4748.namprd06.prod.outlook.com (2603:10b6:5:fd::18) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from aremote02.aus.cypress.com (12.110.209.245) by MN2PR01CA0061.prod.exchangelabs.com (2603:10b6:208:23f::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.19 via Frontend Transport; Mon, 4 May 2020 06:08:59 +0000 X-Mailer: git-send-email 2.1.0 X-Originating-IP: [12.110.209.245] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 3755ff32-c665-43b7-dbff-08d7eff1a305 X-MS-TrafficTypeDiagnostic: DM6PR06MB4283:|DM6PR06MB4283: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8882; X-Forefront-PRVS: 03932714EB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: lLXk9ohww6ZvaYNLL7eqsIP75vLr64CvoUL87qyWfWjThojDq0w7pVRsZS3W1yo3EC571rKGEZ897eLJshk59E2bXj5Hjsiq6Py4HoCxQIxIQrsn094jwG6iIV5uEfiuwXJ7J9f9+W0N9yLCMpQgCFaX51pB1/LYnr6xEQvYKapATbZdSxWxMaY0ZSBJhzbxuT1L4HFNvQUU7+r4Et0hPgLQ5FIqEmpXGFT9MjuMm4NpDCL3MAegXUaQHtxLrz6fBOAWQsXs0CDS7yHfGKoN98OBF8HBnMtknxoJSkP87ZuPYD/9kzfSAEAmrjVc4CIenG/8WkauYkefkBcitQXcC/2tfddJr7z9iNgbt6fBVRKz5R8Pm1hb0/xKX/B0sT42rtZtFsl3VaKPNOyh7BAs8EhbEscMlyR6rJYtbQb8vMZjEPEEQ0REj5UqBRFjmZYu X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM6PR06MB4748.namprd06.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(396003)(39860400002)(366004)(136003)(346002)(376002)(66946007)(66556008)(16526019)(186003)(66476007)(2906002)(26005)(44832011)(7696005)(36756003)(86362001)(52116002)(2616005)(956004)(6636002)(8676002)(5660300002)(8936002)(6486002)(316002)(4326008)(54906003)(478600001)(6666004);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData: 0OE+ElbIOHtjc+3zDqWfQZaNv7M2z991PakYEd1jA4ncscMq43XT4r4HP0jSe8nffFaRp1aTJyV2qfV78EsVRgiueYvP9EZHTeBqwHOIolv+OdZegw8/XFpzhCNr4LKNr0qDg67M9PMe16BSENfvcJojyfXqza922SEh6Xjfnj4qpa3tBF6Qay/ylITVdwajzFhrWX7dVtWEHoMrA1BoeQn63IHl034eija4ZbNef50w6xFHl8f6r5NyTnbFoWliKCEWTwlX52u/t+IIY9YBQ9BpfwoaEgZM37QJ2aBRp03QIH3c11sFMWOOWley2aXj8YqGabz16UrYTGW90aeerlThepOtWfFT9jiRRDYwpGMWXCM9VR5FdceEUgZ2B67o3J34zF+BxG4EzLug+RfZsT9vZoLfqgZWlxgkgGwyuae1NoJmgdItRF7LciZ+FsWpyz5yZgzaS2bpUVaEHzexsVrIqshl6sHLiZymB7sYN1p9KtyLwcljcyz+jWCMJWJzk3tHJt5eB3MECj26M+YKEgma9AfG25s7tjjrfvOtE8mrXgaGct9NZTRgtazo9XdJakDFZo+9fhmxu/LW/rY0l6ebxl+boR9vW3ARWL1hZ52Kni6TwzPHJMcQ7hyzf5dHvtTMlncUU+hPM4l288lUwnuHZo3flec6t7zFDFs49vdEzq9mqUeaoeGtORY/3vfpKu+VirwtjUEil28Vbctddi8t/3yW4dvfUPXEJrvtsqaaux1UtSko3z6ruYbKHI47eGZBogERbp/mW3t7LFXNCfR4sTWVPVXaepsXAKB25k4= X-OriginatorOrg: cypress.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3755ff32-c665-43b7-dbff-08d7eff1a305 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 May 2020 06:09:00.0539 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 011addfc-2c09-450d-8938-e0bbc2dd2376 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: pcUKFmCv/4qBA5R8APpdeKe3A6V8CGKgTDEqLN2rTQVqtIEodjAjEJH7tkza15UkFT1m7v4Njj29qq1dGq+i/w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR06MB4283 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org With RSDB feature, firmware is able to support two P2P-AGO or two P2P-GC at the same time. So we add the second p2p connection type to map to the second P2P connection bsscfg. Signed-off-by: Wright Feng Signed-off-by: Chi-hsien Lin --- .../net/wireless/broadcom/brcm80211/brcmfmac/p2p.c | 56 ++++++++++++++++++---- .../net/wireless/broadcom/brcm80211/brcmfmac/p2p.h | 9 ++-- 2 files changed, 54 insertions(+), 11 deletions(-) diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c index 1f5deea..521b507 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c @@ -17,6 +17,7 @@ #include "fwil_types.h" #include "p2p.h" #include "cfg80211.h" +#include "feature.h" /* parameters used for p2p escan */ #define P2PAPI_SCAN_NPROBES 1 @@ -474,9 +475,13 @@ static void brcmf_p2p_generate_bss_mac(struct brcmf_p2p_info *p2p, u8 *dev_addr) * BSSCFGs need to simultaneously co-exist, then this address must be * different from the P2P Device Address, but also locally administered. */ - memcpy(p2p->int_addr, p2p->dev_addr, ETH_ALEN); - p2p->int_addr[0] |= 0x02; - p2p->int_addr[4] ^= 0x80; + memcpy(p2p->conn_int_addr, p2p->dev_addr, ETH_ALEN); + p2p->conn_int_addr[0] |= 0x02; + p2p->conn_int_addr[4] ^= 0x80; + + memcpy(p2p->conn2_int_addr, p2p->dev_addr, ETH_ALEN); + p2p->conn2_int_addr[0] |= 0x02; + p2p->conn2_int_addr[4] ^= 0x90; } /** @@ -1994,7 +1999,7 @@ int brcmf_p2p_ifchange(struct brcmf_cfg80211_info *cfg, if_request.type = cpu_to_le16((u16)if_type); if_request.chspec = cpu_to_le16(chanspec); - memcpy(if_request.addr, p2p->int_addr, sizeof(if_request.addr)); + memcpy(if_request.addr, p2p->conn_int_addr, sizeof(if_request.addr)); brcmf_cfg80211_arm_vif_event(cfg, vif); err = brcmf_fil_iovar_data_set(vif->ifp, "p2p_ifupd", &if_request, @@ -2149,6 +2154,27 @@ static struct wireless_dev *brcmf_p2p_create_p2pdev(struct brcmf_p2p_info *p2p, return ERR_PTR(err); } +int brcmf_p2p_get_conn_idx(struct brcmf_cfg80211_info *cfg) +{ + int i; + struct brcmf_if *ifp = netdev_priv(cfg_to_ndev(cfg)); + + if (!ifp) + return -ENODEV; + + for (i = P2PAPI_BSSCFG_CONNECTION; i < P2PAPI_BSSCFG_MAX; i++) { + if (!cfg->p2p.bss_idx[i].vif) { + if (i == P2PAPI_BSSCFG_CONNECTION2 && + !(brcmf_feat_is_enabled(ifp, BRCMF_FEAT_RSDB))) { + brcmf_err("Multi p2p not supported"); + return -EIO; + } + return i; + } + } + return -EIO; +} + /** * brcmf_p2p_add_vif() - create a new P2P virtual interface. * @@ -2168,7 +2194,9 @@ struct wireless_dev *brcmf_p2p_add_vif(struct wiphy *wiphy, const char *name, struct brcmf_pub *drvr = cfg->pub; struct brcmf_cfg80211_vif *vif; enum brcmf_fil_p2p_if_types iftype; - int err; + int err = 0; + int connidx; + u8 *p2p_intf_addr; if (brcmf_cfg80211_vif_event_armed(cfg)) return ERR_PTR(-EBUSY); @@ -2194,9 +2222,21 @@ struct wireless_dev *brcmf_p2p_add_vif(struct wiphy *wiphy, const char *name, return (struct wireless_dev *)vif; brcmf_cfg80211_arm_vif_event(cfg, vif); - err = brcmf_p2p_request_p2p_if(&cfg->p2p, ifp, cfg->p2p.int_addr, - iftype); + connidx = brcmf_p2p_get_conn_idx(cfg); + + if (connidx == P2PAPI_BSSCFG_CONNECTION) + p2p_intf_addr = cfg->p2p.conn_int_addr; + else if (connidx == P2PAPI_BSSCFG_CONNECTION2) + p2p_intf_addr = cfg->p2p.conn2_int_addr; + else + err = -EINVAL; + + if (!err) + err = brcmf_p2p_request_p2p_if(&cfg->p2p, ifp, + p2p_intf_addr, iftype); + if (err) { + brcmf_err("request p2p interface failed\n"); brcmf_cfg80211_arm_vif_event(cfg, NULL); goto fail; } @@ -2228,7 +2268,7 @@ struct wireless_dev *brcmf_p2p_add_vif(struct wiphy *wiphy, const char *name, goto fail; } - cfg->p2p.bss_idx[P2PAPI_BSSCFG_CONNECTION].vif = vif; + cfg->p2p.bss_idx[connidx].vif = vif; /* Disable firmware roaming for P2P interface */ brcmf_fil_iovar_int_set(ifp, "roam_off", 1); if (iftype == BRCMF_FIL_P2P_IF_GO) { diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.h b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.h index 64ab9b6..d2ecee5 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.h +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.h @@ -14,13 +14,15 @@ struct brcmf_cfg80211_info; * * @P2PAPI_BSSCFG_PRIMARY: maps to driver's primary bsscfg. * @P2PAPI_BSSCFG_DEVICE: maps to driver's P2P device discovery bsscfg. - * @P2PAPI_BSSCFG_CONNECTION: maps to driver's P2P connection bsscfg. + * @P2PAPI_BSSCFG_CONNECTION: maps to driver's 1st P2P connection bsscfg. + * @P2PAPI_BSSCFG_CONNECTION2: maps to driver's 2nd P2P connection bsscfg. * @P2PAPI_BSSCFG_MAX: used for range checking. */ enum p2p_bss_type { P2PAPI_BSSCFG_PRIMARY, /* maps to driver's primary bsscfg */ P2PAPI_BSSCFG_DEVICE, /* maps to driver's P2P device discovery bsscfg */ - P2PAPI_BSSCFG_CONNECTION, /* maps to driver's P2P connection bsscfg */ + P2PAPI_BSSCFG_CONNECTION, /* driver's 1st P2P connection bsscfg */ + P2PAPI_BSSCFG_CONNECTION2, /* driver's 2nd P2P connection bsscfg */ P2PAPI_BSSCFG_MAX }; @@ -119,7 +121,8 @@ struct brcmf_p2p_info { struct brcmf_cfg80211_info *cfg; unsigned long status; u8 dev_addr[ETH_ALEN]; - u8 int_addr[ETH_ALEN]; + u8 conn_int_addr[ETH_ALEN]; + u8 conn2_int_addr[ETH_ALEN]; struct p2p_bss bss_idx[P2PAPI_BSSCFG_MAX]; struct timer_list listen_timer; u8 listen_channel; From patchwork Mon May 4 06:07:32 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wright Feng X-Patchwork-Id: 11525055 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8AE6017E8 for ; Mon, 4 May 2020 06:09:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 732F8206D9 for ; Mon, 4 May 2020 06:09:14 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=cypress.com header.i=@cypress.com header.b="AUxDXONP" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726742AbgEDGJF (ORCPT ); Mon, 4 May 2020 02:09:05 -0400 Received: from mail-bn8nam12on2092.outbound.protection.outlook.com ([40.107.237.92]:14944 "EHLO NAM12-BN8-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726445AbgEDGJE (ORCPT ); Mon, 4 May 2020 02:09:04 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Xye+bWFOpy8NqKz8al6n8nPHq40DLrhY/9y7EA/+Mk+j2tzGQu6RZG1m4HW+bjARpb22J/20gk7nE60QnFiQMozkYLpwQme2nR8J/v238Z+4L7vkxMDNxdKxLmeBLVXveT5xBT9c8zc9eDsgW4JIFi7wMv4s/iEPwFAfp5dal/N++mjCNO7vzf884jOp6FBobX2r/bVywXwLd0GM/qPmvFqquzI/zaVo8s4YhqpaNRTBiPK3Tqw9lqL3I43nGiFTUePvoRWJNu0moIc3M2sONYgCJSwwouJrQI4GyEiRYKyzEzldUBRnOrq9gQrXcbuo1nHeRET5yHVgWkonk1Y58w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=1GiFcN081O8TeisS6Pvf2/6FQwnT59lHkvf9ezDC20w=; b=DyjC3Pfvmlf6WMbKgdVzUj6ge/cPpOC6hONCKUXtVwqCFLWCiPN/Mz0AaxCmAAozV4BN7IbmMMol+V8HPKl1+lj0chhL1CheCcRI4EZ/Dmby9nHwSPHcNBW7ciAKglNEGQ3hdyNgXnGAPxTpic9QQNi6XSOts4Pe0xiiyA9PRV1FC+t+sRAL0zmH8/T6OY9/UUex6W8K0cP2GGjiN/wxAtUzNa40I6NRXw+cKRRT/Gqq7JgDVuWZqSbNpti3UxkjiQd3qnzvCW0J4toxlbZDH3ORFZ04IJVTrhs7RkUW8js3acbb567qFIDBYqm0kG4z92gMe+sZObUrXKAuaX9lpQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=cypress.com; dmarc=pass action=none header.from=cypress.com; dkim=pass header.d=cypress.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cypress.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=1GiFcN081O8TeisS6Pvf2/6FQwnT59lHkvf9ezDC20w=; b=AUxDXONPQ1CuWO52xKDXkLrG+SUM08xIY1qBeGOcCjo2Wz0S8XHNOLx87Cbhz77/c6we6zUnI/nquNxElQz/yTBXKMJofHyY1RPo1fzImRl1cxmh3dIx6XTy2VLDKjBrnuoaydfY1/4Ohs9m6cc87q+ZCORhugkACfR+1XtS74Y= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=cypress.com; Received: from DM6PR06MB4748.namprd06.prod.outlook.com (2603:10b6:5:fd::18) by DM6PR06MB4283.namprd06.prod.outlook.com (2603:10b6:5:1e::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.29; Mon, 4 May 2020 06:09:02 +0000 Received: from DM6PR06MB4748.namprd06.prod.outlook.com ([fe80::ad0b:eda4:4eb8:b8d7]) by DM6PR06MB4748.namprd06.prod.outlook.com ([fe80::ad0b:eda4:4eb8:b8d7%7]) with mapi id 15.20.2958.027; Mon, 4 May 2020 06:09:02 +0000 From: Wright Feng To: linux-wireless@vger.kernel.org, chi-hsien.lin@cypress.com Cc: wright.feng@cypress.com, brcm80211-dev-list@broadcom.com, brcm80211-dev-list@cypress.com, Arend van Spriel , Franky Lin , Hante Meuleman , Kalle Valo , Joseph Chuang Subject: [PATCH 2/3] brcmfmac: Fix P2P Group Formation failure via Go-neg method Date: Mon, 4 May 2020 01:07:32 -0500 Message-Id: <1588572453-194663-3-git-send-email-wright.feng@cypress.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1588572453-194663-1-git-send-email-wright.feng@cypress.com> References: <1588572453-194663-1-git-send-email-wright.feng@cypress.com> X-ClientProxiedBy: MN2PR01CA0061.prod.exchangelabs.com (2603:10b6:208:23f::30) To DM6PR06MB4748.namprd06.prod.outlook.com (2603:10b6:5:fd::18) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from aremote02.aus.cypress.com (12.110.209.245) by MN2PR01CA0061.prod.exchangelabs.com (2603:10b6:208:23f::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.19 via Frontend Transport; Mon, 4 May 2020 06:09:01 +0000 X-Mailer: git-send-email 2.1.0 X-Originating-IP: [12.110.209.245] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 27ece04a-db1d-4cb3-8784-08d7eff1a453 X-MS-TrafficTypeDiagnostic: DM6PR06MB4283:|DM6PR06MB4283: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5797; X-Forefront-PRVS: 03932714EB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: zN6f0lsYFdifn+gUPDM9xO15sm2PpdkM1532PhYnPsqUreijiBB47ZSWwJpKtFs2WEyXhxVtbfODRsrEZoMeGz5JNBIoukFesEKDOKuoqoJjV6np04MDlsl55m4z9AtL6HvRs7Z9iWnMYfT97ccv2L237LXdCXkVwoAbUcyDEJhteWadC1sQc7Iq6cQ9rYWa2R56VpusbyxaxzSrE6LXhofc3nVkH4Euf37s4BPUg+V1lxVX8krkLDrOY58x+DwpIa3oTNdqnpTLIYy9ZgSdUPuf50xeeTmlnwCYhqqs7CXwh/17wQvChMLhyBElI67dh4nOvdePwai1g4FaOWI+/ewSlWEL0/Ls9QsK0xiaK3EuO2TLNNlLjspF+l3RjGCsaSpoQe56XWAsF8zevc0eDY5WfbVGGK4crTJSZKPn7JPU2H5s1kiRioST76USvsXa X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM6PR06MB4748.namprd06.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(396003)(39860400002)(366004)(136003)(346002)(376002)(66946007)(66556008)(16526019)(186003)(66476007)(2906002)(26005)(44832011)(7696005)(36756003)(86362001)(52116002)(2616005)(107886003)(956004)(6636002)(8676002)(5660300002)(8936002)(6486002)(316002)(4326008)(54906003)(478600001)(6666004);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData: VCyiKLjMCJmnGibjbKkfiBREdkXSWXU+AKb0gtu05jLuoTjS4rT5hI2mVO95pmPdguRfj3jwD54MHhroZVox0Ceqv963WEbVO/ruHrN87aX7ueUgh4Md+9ApjJV2YKbL5W3jtvnSflFiM6Xgltl1LiYEF3mNsg4bAvdiycRjQVaP0zU66jm53i0Rlbsu7t4j4AA3//XKTHspwpK12DIxVhTcthZV1gT6XoV0wZZg5A0+QhZxTU1yJVKYKmE5tClitnJ8cDyLPtB9bPD2CGpJoTKBuMkFPx8oDBciN6F5zfZYoPxgWTWBdKenyQq3eFE2vefkJ0lHLdXUlYuPHE9FQOhLex2Tug222HhNSW4BecPCmiyZhUuAZ6hb8DLxngn+9IEZceWvA2cwvWFIhcvNkIzyZ34VosYm3k+trcl0OReZ9+avBs+Jv0DM0JEa2aFGxv24puopvQYOXOwQwuNExe3oqgHkZVJHuYII6ydbLyqvMku4++vi10TUVmapwWp+xpe4b94jqub/JNoHqF0CyyRwNDG3uo9XYpq2zeDS/j2XOadycj2vBm94qnhc+0aTrHnWexySHw5IIV7WlYsphbkbSAh+t3YIS2H4nyuWmhbg/JgTHntEZ5GmdURm+CzlVf2vNq5FEowch8JlgM9Pdnip/IyYeSx7f/ydOYj5FhRTCc1X8aWsFp/mLMb5Cwq99icxFxju8+laE09TeLYrl1bG9CBw/FplMdkawm26aBqYitey1th5a6VDO82sQmDy4cYzBm6xV/P/u8KudoX2DfSybgUDwbJAtMjn6DHcQrs= X-OriginatorOrg: cypress.com X-MS-Exchange-CrossTenant-Network-Message-Id: 27ece04a-db1d-4cb3-8784-08d7eff1a453 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 May 2020 06:09:02.2966 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 011addfc-2c09-450d-8938-e0bbc2dd2376 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Yca/X7DUP7xyklr2CRwsebgcskQOBzltgZndrqb6vWChWSdEwNqywDQfB+C3kt7lk+Ggk6qCTLwmigOltiLreA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR06MB4283 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: Joseph Chuang P2P group formation fails since either peer is not able to send go-neg confirm or dut is not able to send go-neg response. To fix this, retry limit should be increased and dwell time check should be added. Signed-off-by: Joseph Chuang --- .../net/wireless/broadcom/brcm80211/brcmfmac/p2p.c | 28 ++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c index 521b507..cb8e229 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c @@ -60,7 +60,7 @@ #define P2P_AF_MIN_DWELL_TIME 100 #define P2P_AF_MED_DWELL_TIME 400 #define P2P_AF_LONG_DWELL_TIME 1000 -#define P2P_AF_TX_MAX_RETRY 1 +#define P2P_AF_TX_MAX_RETRY 5 #define P2P_AF_MAX_WAIT_TIME msecs_to_jiffies(2000) #define P2P_INVALID_CHANNEL -1 #define P2P_CHANNEL_SYNC_RETRY 5 @@ -93,6 +93,9 @@ #define P2PSD_ACTION_ID_GAS_CRESP 0x0d /* GAS Comback Response AF */ #define BRCMF_P2P_DISABLE_TIMEOUT msecs_to_jiffies(500) + +/* Mask for retry counter of custom dwell time */ +#define CUSTOM_RETRY_MASK 0xff000000 /** * struct brcmf_p2p_disc_st_le - set discovery state in firmware. * @@ -1645,6 +1648,17 @@ static s32 brcmf_p2p_pub_af_tx(struct brcmf_cfg80211_info *cfg, return err; } +static bool brcmf_p2p_check_dwell_overflow(s32 requested_dwell, + unsigned long dwell_jiffies) +{ + if ((requested_dwell & CUSTOM_RETRY_MASK) && + (jiffies_to_msecs(jiffies - dwell_jiffies) > + (requested_dwell & ~CUSTOM_RETRY_MASK))) { + brcmf_err("Action frame TX retry time over dwell time!\n"); + return true; + } + return false; +} /** * brcmf_p2p_send_action_frame() - send action frame . * @@ -1669,6 +1683,10 @@ bool brcmf_p2p_send_action_frame(struct brcmf_cfg80211_info *cfg, s32 tx_retry; s32 extra_listen_time; uint delta_ms; + unsigned long dwell_jiffies = 0; + bool dwell_overflow = false; + + s32 requested_dwell = af_params->dwell_time; action_frame = &af_params->action_frame; action_frame_len = le16_to_cpu(action_frame->len); @@ -1780,12 +1798,18 @@ bool brcmf_p2p_send_action_frame(struct brcmf_cfg80211_info *cfg, /* update channel */ af_params->channel = cpu_to_le32(afx_hdl->peer_chan); } + dwell_jiffies = jiffies; + dwell_overflow = brcmf_p2p_check_dwell_overflow(requested_dwell, + dwell_jiffies); tx_retry = 0; while (!p2p->block_gon_req_tx && - (ack == false) && (tx_retry < P2P_AF_TX_MAX_RETRY)) { + (!ack) && (tx_retry < P2P_AF_TX_MAX_RETRY) && + !dwell_overflow) { ack = !brcmf_p2p_tx_action_frame(p2p, af_params); tx_retry++; + dwell_overflow = brcmf_p2p_check_dwell_overflow(requested_dwell, + dwell_jiffies); } if (ack == false) { bphy_err(drvr, "Failed to send Action Frame(retry %d)\n", From patchwork Mon May 4 06:07:33 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wright Feng X-Patchwork-Id: 11525057 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B108419A2 for ; Mon, 4 May 2020 06:09:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8FDF6206D9 for ; Mon, 4 May 2020 06:09:14 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=cypress.com header.i=@cypress.com header.b="pf16vaz/" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726751AbgEDGJH (ORCPT ); Mon, 4 May 2020 02:09:07 -0400 Received: from mail-bn8nam12on2092.outbound.protection.outlook.com ([40.107.237.92]:14944 "EHLO NAM12-BN8-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726410AbgEDGJG (ORCPT ); Mon, 4 May 2020 02:09:06 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZiuoXUjAYgC/ASVm58Skk0ID4M0lEv8Rur+n8xbdWOq2qH45YNebAjd2qF7sA+jhe4AnEJNAkYG/M9cHvHpV6/XVtAYJyG9s+uUjJ+InWsB1W6zNH/VygPn8xEBtXNB3T/WD2k/gNPgQ+FeAJvizyOq96zKA1WX0W/a/UnhLF+aTfVa7l3y3hfDHLcVRiMECNRgFKvyyH7mO4pDSCTrjVGgsRpA3og5SLrdxFqlKLclN6B4gl9ErcjE30znpGkzLInWf3tCXAlMpeYhPQiaYQl/oQp2TXz4SXcWC08bL6nGMCVLtGkmaqHTJazJ27RpgIBWoUCv7eDVo4JwdCnzWHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Uhr+tcgIeol6CoKuWP0Igk2XuSvWYppqWZpc4IKdWlI=; b=AE0We/G0bbeuHFCuPuA+L2/712tB4NgfxmpT6ZxG4hEE6Imy2br/AG1rOGElhynmmSdN1POuUn2Ne+E9rZk9Qcx5hROxAtNDr0fs9z+T1N4sHb/tBVckL6EUsmHeAhE3lzIB2UhBMhACPDfgLZH+dMyUCk76z8tQ+hAlk9Fy8CKJBFbeqtbZ8cu9hXIY55nZDBHjq3gRozhxbt+mCqSIZt8F3OnuTSNED8Cv64cjq0NJo1l4RU8VOJ9jgKned1/VMu+rqdlbkaE/MAGICUJ6MVYnRvFbW4z9s2pi07IcImK5hESYt00Svjp5oaUTJzZHICsDIUhiD5dBoPckAe9Jnw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=cypress.com; dmarc=pass action=none header.from=cypress.com; dkim=pass header.d=cypress.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cypress.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Uhr+tcgIeol6CoKuWP0Igk2XuSvWYppqWZpc4IKdWlI=; b=pf16vaz/RlZuuPuKtCuBtE+6V83yUs7d5/lYoaFZ9n1CoWTzH+ynGNYZmZpYSWlIgC+uUKm7JzEzFfoLMkcpMHyrOxd22zX3Yi9hCyV4YNduOm6Ly4c8Mxr43i2KsqfEWbqISJrF7Lb+ZTZKYO35HPCdNxq+uPMa7fbnC+eeBvo= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=cypress.com; Received: from DM6PR06MB4748.namprd06.prod.outlook.com (2603:10b6:5:fd::18) by DM6PR06MB4283.namprd06.prod.outlook.com (2603:10b6:5:1e::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.29; Mon, 4 May 2020 06:09:04 +0000 Received: from DM6PR06MB4748.namprd06.prod.outlook.com ([fe80::ad0b:eda4:4eb8:b8d7]) by DM6PR06MB4748.namprd06.prod.outlook.com ([fe80::ad0b:eda4:4eb8:b8d7%7]) with mapi id 15.20.2958.027; Mon, 4 May 2020 06:09:04 +0000 From: Wright Feng To: linux-wireless@vger.kernel.org, chi-hsien.lin@cypress.com Cc: wright.feng@cypress.com, brcm80211-dev-list@broadcom.com, brcm80211-dev-list@cypress.com, Arend van Spriel , Franky Lin , Hante Meuleman , Kalle Valo , Justin Li Subject: [PATCH 3/3] brcmfmac: Add P2P Action Frame retry delay to fix GAS Comeback Response failure issue Date: Mon, 4 May 2020 01:07:33 -0500 Message-Id: <1588572453-194663-4-git-send-email-wright.feng@cypress.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1588572453-194663-1-git-send-email-wright.feng@cypress.com> References: <1588572453-194663-1-git-send-email-wright.feng@cypress.com> X-ClientProxiedBy: MN2PR01CA0061.prod.exchangelabs.com (2603:10b6:208:23f::30) To DM6PR06MB4748.namprd06.prod.outlook.com (2603:10b6:5:fd::18) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from aremote02.aus.cypress.com (12.110.209.245) by MN2PR01CA0061.prod.exchangelabs.com (2603:10b6:208:23f::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.19 via Frontend Transport; Mon, 4 May 2020 06:09:03 +0000 X-Mailer: git-send-email 2.1.0 X-Originating-IP: [12.110.209.245] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 57d846e8-bd1a-48c8-a122-08d7eff1a58a X-MS-TrafficTypeDiagnostic: DM6PR06MB4283:|DM6PR06MB4283: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8273; X-Forefront-PRVS: 03932714EB X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: EGfO+e2gYM7Mjf5qJxTzsKsexuyw3ez63AxAlQ+SgUY5LZxuCmKjDkdIG6SWrwS7nwL3EIJpVwla/KRpVe76XHWJ60Uun2HTJU6otjKGI4re3wTyxtTcEOcJP2UqjLdn8zxZ5useOPdliFtGJH+J/cGMF7LDwVgDdnvHZeo9YG10zxMxbk1PKLSa7pwu3YYTY902sw9dcIYhzIjn5SiUU6XTPdL4VA50c6FwGLzYNPJcbPXq+KEBPtqM2MkbckqQdhdrCVSXy+7SXPBJJklv9ykfJZkkvetxJJlPwUnpQuQUfffsrbHUsDzwJLw4WuuH7v7rVqM9o/eUm4jgFoWE4Dmd/BAHSuTjjfCn+urN30kVG9vQ4ljXjvGanmXSDqeD+aM0/qs9QNgfu0NgtoOKzJIbRYdDGbQ4gBt1uqwU3B0N01NnFew/SXE3BSJpV0cJ X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM6PR06MB4748.namprd06.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(396003)(39860400002)(366004)(136003)(346002)(376002)(66946007)(66556008)(16526019)(186003)(66476007)(2906002)(26005)(44832011)(7696005)(36756003)(86362001)(52116002)(2616005)(107886003)(956004)(6636002)(8676002)(5660300002)(8936002)(6486002)(316002)(4326008)(54906003)(478600001)(6666004);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData: Z+aTHMGBFWB6NjX8krmHT4QUipkLiFtdPFsfreNoh6TDemEBvxz50o7+uk2rOp57hw2e0nSiDcDJRPMLXgdAJy2dXxvDcKMeSwCbDj4wtLJ16lieC4eJI6YV8ur9Kw2h9ojV3Fu1n0mQp+kIfbVV8IJxBx4U7BkxsHwdt+NC+75oZ+atP27OnOQ2qFetKsrvQY3sTwddsShH87T2OicqH7Cu1qOCHEEPMZevboUWJbYmjIfXGSPd/T+b41XZopVoh7+JYm6ljRQ/coK5RFlUncs0oDlUhrG5K1njOaTjBcgPq+1niyhnyyiuMolXxK+H0UjPPPVDb0LNvfQaSh/Aulw5Yxey3WGLH0iGRZiizWtn1jv6A8EKRVKIRy8CTzaukHs+kMAY8TF5K8v8wDzXQV5OTwxnJl+Za/A1iqP0boCYQkS6VE6wRnFzO+hu8VsjTaWgY8WF1mjuetu8SgBIbpc03o14M6/A7c6ToG0+EftnED1bFk4uuCHBe1gBlmad+/qFEz5O85505sJk+wp0YgFGuFAzoqr3ywDvSEcUmauFHPa5k1fAijy2203xXIX1IpEUpTJbktZJLbCHrmjzHfba3Dn2xLmI3WWNxTPXQ66lNQ6/Mbnb+z4pT735qG7hR88j1K5ivs2sUTExaRiBEkl/mt+XgXVtXxZIXPwZTUsupzLnu+zqZvvYav+osCagJsGvZbUMLy4IMIZ8Elaoejb67pQjFR5HbminC9RzpRNvL+SxdCDy8yB0AB4r26Yilr3ULCarRRfZfpmqcSqxYsoSc2J8lqs+efb5qZo9Hxw= X-OriginatorOrg: cypress.com X-MS-Exchange-CrossTenant-Network-Message-Id: 57d846e8-bd1a-48c8-a122-08d7eff1a58a X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 May 2020 06:09:04.3135 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 011addfc-2c09-450d-8938-e0bbc2dd2376 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 1P3RSbCon86BgEYTSFY6rG96lqbj4dJejajqeiDiZANr+6tExilEhxOQQf2SI4EcumD7zcgr+UPu10ww85K5iQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR06MB4283 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: Justin Li It was observed that P2P Cert. 5.1.19: DEVUT responds to Service Discovery request failed due to DUT did not send GAS Comeback Response after receiving request from test bed P2P peer. To fix this issue, we need to add P2P Action Frame retry delay to enhance P2P connection under VSDB and noisy environment, since the peer can be in other channels under VSDB. Signed-off-by: Justin Li Signed-off-by: Chi-hsien Lin --- drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c index cb8e229..780fe21 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/p2p.c @@ -66,6 +66,7 @@ #define P2P_CHANNEL_SYNC_RETRY 5 #define P2P_AF_FRM_SCAN_MAX_WAIT msecs_to_jiffies(450) #define P2P_DEFAULT_SLEEP_TIME_VSDB 200 +#define P2P_AF_RETRY_DELAY_TIME 40 /* WiFi P2P Public Action Frame OUI Subtypes */ #define P2P_PAF_GON_REQ 0 /* Group Owner Negotiation Req */ @@ -1806,6 +1807,9 @@ bool brcmf_p2p_send_action_frame(struct brcmf_cfg80211_info *cfg, while (!p2p->block_gon_req_tx && (!ack) && (tx_retry < P2P_AF_TX_MAX_RETRY) && !dwell_overflow) { + if (af_params->channel) + msleep(P2P_AF_RETRY_DELAY_TIME); + ack = !brcmf_p2p_tx_action_frame(p2p, af_params); tx_retry++; dwell_overflow = brcmf_p2p_check_dwell_overflow(requested_dwell,