From patchwork Fri Oct 20 03:48:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Lin X-Patchwork-Id: 736594 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CD4AFC001DF for ; Fri, 20 Oct 2023 03:48:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346928AbjJTDs0 (ORCPT ); Thu, 19 Oct 2023 23:48:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52414 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1376295AbjJTDsX (ORCPT ); Thu, 19 Oct 2023 23:48:23 -0400 Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2050.outbound.protection.outlook.com [40.107.21.50]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 597EAD5D; Thu, 19 Oct 2023 20:48:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=BiZu3K0mtrHSZC84pdkDshSiRFEfoLy2VKw6sZsDpfHCPIisn0l9mO/HSXcKwqeb/j35Qz7QNJURGCd9wz0kIvLd4T1JPLk+YIpiiAp8e7hHDYFjFrzs68dZsuag0OwwSh8glTcfKtkePxrYAQ/xVFJZT74/THcQZD2tNiqeAPa954hmLvY6mheS75toNbYLk7lL2XH8Tfa6o+IO9j40rNfM73bFd8fAaAdwDZczSF8ERpwmMBv4su2g7STwa+edI2/cmgfQkrS4sGg/yREe0pXKlaqvMhEnkKx6fLpICVCPKjSCXv2WjYOE+jq8iNRgdMfHsCgbp7DltFPY8X/OeA== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=XZU9nOm2Yensoyv6sYH4rYubgfZwwZbRFAcGUo23CQI=; b=KIbnbMjLqTeDvtFvnz/J50TBQygxor7bEb3q5oy6C/M4JsCTanbO7aK9cMtxexJdcX0CpQJ6kAo7eF/4IQb94F0tHSxFjISnPmsaArxXlGcy1eEBTCDqNPcfaCPKYzId/9/SlD8QfJO2Ob67l+IXxyuMDLSj6ogl2ImfWhwecDHORvRivRmzWvcvjfHQ8ZmpU4lv8TZEGBiVqAttlsx9i/1grMxVv240GgE/7mH2pOYnEBQudTAiTqGqybySHDVfZwm4DOmFdbAlOgnw7pkVYulmcNPI9n3bxX8VZ8lRV3/II4EDuBFaN7SGSTHVtWueUzkMRHY0sxWGGsRI7z4EiQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XZU9nOm2Yensoyv6sYH4rYubgfZwwZbRFAcGUo23CQI=; b=rdHiwpxzzgJxgS7tdTRDGb53p1zrdsvdJyqsQMePzfssZ/0kI+h+7W8Fwos3U6b49WwKQWNf4j9osoqCez3no5DZrtm9M6mX3xePHoh49HwRIPXeJPWF+4z3H5wRUSRsuH+qr//2FktUVjmRAWcO7Mr110ajQ0RI1SW5gqnidtc= Received: from PA4PR04MB9638.eurprd04.prod.outlook.com (2603:10a6:102:273::20) by VI1PR04MB7069.eurprd04.prod.outlook.com (2603:10a6:800:127::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6933.11; Fri, 20 Oct 2023 03:48:14 +0000 Received: from PA4PR04MB9638.eurprd04.prod.outlook.com ([fe80::34dd:289e:9e8b:9c9b]) by PA4PR04MB9638.eurprd04.prod.outlook.com ([fe80::34dd:289e:9e8b:9c9b%7]) with mapi id 15.20.6933.011; Fri, 20 Oct 2023 03:48:14 +0000 From: David Lin To: "linux-wireless@vger.kernel.org" CC: "linux-kernel@vger.kernel.org" , "briannorris@chromium.org" , "kvalo@kernel.org" , "francesco@dolcini.it" , Sharvari Harisangam , David Lin , Pete Hsieh Subject: [PATCH v6 2/6] wifi: mwifiex: fixed group rekey issue for WPA3. Thread-Topic: [PATCH v6 2/6] wifi: mwifiex: fixed group rekey issue for WPA3. Thread-Index: AdoDCD/stmTqfaxRSnefie6i84io6w== Date: Fri, 20 Oct 2023 03:48:14 +0000 Message-ID: Accept-Language: zh-TW, en-US Content-Language: zh-TW X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: PA4PR04MB9638:EE_|VI1PR04MB7069:EE_ x-ms-office365-filtering-correlation-id: 146c5c20-63b0-4820-8e00-08dbd11f6368 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: JCX6Rv23ajLYjX45aBk+OmdhxGZLJ0ZIhUwOcVKlLZhmex8WawMXtpQPrHSjgxwlJLSHimf6WKeGWz9Zwtx4ccifW5fXg2SqPH8HsUEpjEFAZn5GDw59q/zn/A0StQsTJUv+RDoUsjQzh8v1tP27vcV8lJKjEte49uIeO30W2E6Qqk7myXbFoM8qopQB+gfdb5QrBHJSyNTo8v3ky0cMfxVAxXhrrt/ZTLWjFhZmKm6lrV14E6nEVDnUfoEvwq4DN6Bh04y5HVht1eff8Zp1LPYWHSbR875NhW/zAimTDOpe6yiMnMskOhEvxPMYqf9DkiLPJKkrF2JP9GfHD6go55qVr61GdaiVPgl90Yl/d99vxoplNiqbuynxroESpd7u+mYEKl1HTztG1YfNy+Z4Rud+AULlyBAvZz+XmOuYLP5UPJAsngPBC5knDi+kJFcv1NmXw/JpMy3j3o/I8c94m5EEwatVc7TXR+G8OBki/v/+8ifwKYGp9R/jNqyZe9OX7KCkGjzlUtEiosgSlEzcKEr4KEqthJhj0bH5WeRbaf7wRdShulNFlgvoRMy1w1rzsmJSdnstNekcPkrJFsdluQ4ESnOdmYWFUS1Un3+4PAQfH3559DvEkzHQARpxdMa9 x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PA4PR04MB9638.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(366004)(396003)(136003)(376002)(39860400002)(346002)(230922051799003)(186009)(1800799009)(64100799003)(451199024)(55016003)(38100700002)(41300700001)(4326008)(5660300002)(8676002)(8936002)(52536014)(86362001)(33656002)(2906002)(122000001)(478600001)(83380400001)(9686003)(7696005)(26005)(71200400001)(6506007)(316002)(38070700009)(66946007)(76116006)(54906003)(66476007)(6916009)(66446008)(64756008)(66556008); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: YeECtiLEdD/Otcs/BdcG2uCxJKJ7h7JBxObI1glMrjy6g9Qu9jZ1845ZYdRsYkAK1eRD7NB2UJYwHz7iOrsfjK0/wohCkaLc06f9biSyTmA4Ky7E+5HgQ+AffAfmuXe2WT4pGYuM0/Grbumhvy6oBv31DuD+CrNmKyN5q5wD6Xm83jnee/M1J3uqTigj3lAsAv948DRs3gCPY1BKfJCwqdq+y6dAUhj3c1yvVLM8obkAEURNJ/4CkwQV5ksHjwq6pKkVRInw+plybCiVj6rcLeSPpRHDFhIUhbhIm5YeKLUMZi3q+clOU75S9DL0Uaetw8V8BUdmKh2XLFz+we9FG45pEOLrUq7QmY5vG3JY9S8AF+GpRyDQU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txs2yzFsCONiiEzITMskNMmt6gj6YscSgzqwohNrN9GowD3EdX5Yl2l8QwAT0kk56CAcf+G8uCK4el4vbXe4w+3FUkGaY+KF6L0UguXoMrZnwGxHMQkFZYE4RBiptjosm0lgIfDx8gHP4khQEC0m MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: PA4PR04MB9638.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 146c5c20-63b0-4820-8e00-08dbd11f6368 X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Oct 2023 03:48:14.4890 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: R9m/CRGz0jniHWJVHF12GPL5iXt1Qdveq8V43S/1v0x7PVRwRpJ4LwvEHzmgUVqtSgv90EOe3JPXO91Ine4k+A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB7069 Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org If host mlme is enabled, gropu rekey offload should be disabled. Signed-off-by: David Lin --- drivers/net/wireless/marvell/mwifiex/cfg80211.c | 3 +++ drivers/net/wireless/marvell/mwifiex/main.c | 4 ++++ drivers/net/wireless/marvell/mwifiex/util.c | 7 +++++++ 3 files changed, 14 insertions(+) diff --git a/drivers/net/wireless/marvell/mwifiex/cfg80211.c b/drivers/net/wireless/marvell/mwifiex/cfg80211.c index 40c39e4765f7..3d59e6a441b9 100644 --- a/drivers/net/wireless/marvell/mwifiex/cfg80211.c +++ b/drivers/net/wireless/marvell/mwifiex/cfg80211.c @@ -3657,6 +3657,9 @@ static int mwifiex_set_rekey_data(struct wiphy *wiphy, struct net_device *dev, if (!ISSUPP_FIRMWARE_SUPPLICANT(priv->adapter->fw_cap_info)) return -EOPNOTSUPP; + if (priv->adapter->host_mlme) + return 0; + return mwifiex_send_cmd(priv, HostCmd_CMD_GTK_REKEY_OFFLOAD_CFG, HostCmd_ACT_GEN_SET, 0, data, true); } diff --git a/drivers/net/wireless/marvell/mwifiex/main.c b/drivers/net/wireless/marvell/mwifiex/main.c index d99127dc466e..3bebb6c37604 100644 --- a/drivers/net/wireless/marvell/mwifiex/main.c +++ b/drivers/net/wireless/marvell/mwifiex/main.c @@ -802,6 +802,10 @@ mwifiex_bypass_tx_queue(struct mwifiex_private *priv, "bypass txqueue; eth type %#x, mgmt %d\n", ntohs(eth_hdr->h_proto), mwifiex_is_skb_mgmt_frame(skb)); + if (ntohs(eth_hdr->h_proto) == ETH_P_PAE) + mwifiex_dbg(priv->adapter, MSG, + "key: send EAPOL to %pM\n", + eth_hdr->h_dest); return true; } diff --git a/drivers/net/wireless/marvell/mwifiex/util.c b/drivers/net/wireless/marvell/mwifiex/util.c index 23675c1cecae..ff1b2f162c30 100644 --- a/drivers/net/wireless/marvell/mwifiex/util.c +++ b/drivers/net/wireless/marvell/mwifiex/util.c @@ -482,8 +482,15 @@ mwifiex_process_mgmt_packet(struct mwifiex_private *priv, return 0; if (ieee80211_is_deauth(ieee_hdr->frame_control)) { + mwifiex_dbg(priv->adapter, MSG, + "auth: receive deauth from %pM\n", + ieee_hdr->addr3); priv->auth_flag = 0; priv->auth_alg = 0xFFFF; + } else { + mwifiex_dbg(priv->adapter, MSG, + "assoc: receive disasso from %pM\n", + ieee_hdr->addr3); } }