From patchwork Mon Jan 14 09:39:35 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761781 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-2.web.codeaurora.org (Postfix) with ESMTP id D42B06C2 for ; Mon, 14 Jan 2019 09:40:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C65E328AC8 for ; Mon, 14 Jan 2019 09:40:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C4E4028ACE; Mon, 14 Jan 2019 09:40:29 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 6BAEE28AF8 for ; Mon, 14 Jan 2019 09:40:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726533AbfANJk2 (ORCPT ); Mon, 14 Jan 2019 04:40:28 -0500 Received: from mail-eopbgr780088.outbound.protection.outlook.com ([40.107.78.88]:26800 "EHLO NAM03-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726064AbfANJk2 (ORCPT ); Mon, 14 Jan 2019 04:40:28 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=jTFsucJB0eEaua9mqU1n9S2aN5yM0k8/UZ5dbfKQ+lo=; b=ji0fuP643J5d8FRF14iN811/HqfDTb8HlTrZsj9xiCD2BRiaOgFZt9EeJWnpPDnqQFQV8mPBMGoie4Uzl1jxus/s8ZKhUdCXjtoQjeTzF0USBUYiZtu+JzSzcZ0E/2HQmceCvI0caUD/8Ln406Mk40u+CVFGLusf8YxnrT3UAnI= Received: from DM6PR05MB6347.namprd05.prod.outlook.com (20.178.224.142) by DM6PR05MB6348.namprd05.prod.outlook.com (20.178.224.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.19; Mon, 14 Jan 2019 09:40:18 +0000 Received: from DM6PR05MB6347.namprd05.prod.outlook.com ([fe80::242a:b702:f98c:1dea]) by DM6PR05MB6347.namprd05.prod.outlook.com ([fe80::242a:b702:f98c:1dea%3]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:40:18 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB5838.namprd05.prod.outlook.com (20.177.255.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:35 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:35 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 1/9] qtnfmac: support EBUSY errcode for QLINK protocol Thread-Topic: [PATCH v2 1/9] qtnfmac: support EBUSY errcode for QLINK protocol Thread-Index: AQHUq+0PmRF9JBFGAkmISTg5fGADuA== Date: Mon, 14 Jan 2019 09:39:35 +0000 Message-ID: <20190114093925.9061-2-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM6PR05MB6348;6:ZSrkVDAtofzQHu6mgk7j54Zf4W7xsjDqUK5huugpJuXCclC4yNxXnglRi/AsuU0SAStjkSYXIUUb+NDxJcLGX7tUEY/mnNt0bvEek3fkm5IyIEpmveup+xYh9dPrp/T4TXuLyIDceGl8nH4HE8vVSIAcqnZrS1Da7ja/1hliLuEel8PeAfTEMH9yWLK58kviQzgD/zcBACV2ECvC0g07KCHb6vQoBxt4BU9+N5cQ2RLn08Re7SDTiZOn0+Tw9EIEKmQ9uLyxOTIf4ZaQG+DvLlXojD6wAIWAACNFNp58bExqFWj32kLUPHDFUS3jyA+8w2bDzpmLlvzspBg2o+Ru8U0aSqLpgb0/hJ9hOJUo3a1Fx+saM85BB9yFKzlnQ3i1hdZ1u1w3u/lk8LqiO0XyTVGTZb/G1mnZPLtjmwGBkhdV5iRKFrYyIW4MKa824FJqjwt4SmkX5X4CAAFwqMB5zA==;5:I8VitrmmLiS02XrOkBBhxOEkk6tRNeySqHy8ev3cQr0uNTlYdlESmJBTSkBLWOd1+URjyQOriPnRHT1FMfrN+f+GfMYT4UDhbEd/sP57LtvJ33YEqxSYq+sl8WochaWhpmBitwPjjJKMMBGPi+774U8mnclvAPfpMK1/9LYyXiC8gnPaGjrmLW5b4E+f0mZYV7KWoCQT/1MYM9MIMXrB2A==;7:CDfkI7rVmqWv3fzsQH2+EYgXl0LFjHdMlEWsz3367xT1d7l7cOeoF1WQyZifJOedle//hEUS/tkJZjZxkUMijefxJb9IamUmLNOs/E7PZN+uJdCanp0+s2EUGasGZoYKUFuwwgNkYmT7ZicLQJijyg== x-ms-office365-filtering-correlation-id: 64f696c5-df7c-4f13-c37f-08d67a043162 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600109)(711020)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB5838; x-ms-traffictypediagnostic: SN6PR05MB5838:|DM6PR05MB6348: x-moderation-data: 1/14/2019 9:40:16 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(39830400003)(396003)(366004)(376002)(346002)(136003)(189003)(199004)(107886003)(316002)(6512007)(103116003)(3846002)(53936002)(6916009)(6116002)(5660300001)(105586002)(106356001)(66066001)(7736002)(305945005)(2351001)(68736007)(2501003)(2906002)(97736004)(8676002)(81156014)(81166006)(8936002)(436003)(25786009)(6486002)(71190400001)(446003)(71200400001)(5640700003)(11346002)(2616005)(6436002)(76176011)(52116002)(99286004)(86362001)(186003)(14454004)(478600001)(36756003)(1076003)(54906003)(256004)(102836004)(4326008)(486006)(6506007)(26005)(476003)(386003);DIR:OUT;SFP:1101;SCL:1;SRVR:DM6PR05MB6348;H:DM6PR05MB6347.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: cKWy9gsUJFDG3ye4swvq1jYFA3clFFI+YV+eg2D/bdbDtaS+Gc554fmrO+j7aN89dY2PY5cxx0U5N8pjANriGg7CWfQtoC3tkXCcFp3oizBJxC6P4GDVhRgWI+2jM3Qw2xcKGTgbMx25NXAFEbDylnzrx+eeQNqatehSten0BDLAa784PfnparG5dSHJr9wepChJvVrwmRA02CREZuW68k8HwmLzbN/aHvD5IQw+HJ2tAOuSlevYkzzOBCs0Es5N6vd0caQ73cA4ERxvl6WC5uNl0XpWhQ+3Q5L3jDu+EG7tdWapu8HVBc+2V4h2MpyMGlVYJ2GhVubSkvOGtaTF+InYIkVJU7iGfuqyIBu/GFVHdf9FLSSK8VEFLHaAFXqSjTHRRaOp1yIWbvWoLRr+ogZbdMcXNz7cN3QP4W3OFyM= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: 64f696c5-df7c-4f13-c37f-08d67a043162 X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:18.7322 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR05MB6348 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: Andrey Shevchenko Add support of EBUSY error code for remote procedures over QLINK protocol. Signed-off-by: Andrey Shevchenko --- drivers/net/wireless/quantenna/qtnfmac/commands.c | 2 ++ drivers/net/wireless/quantenna/qtnfmac/qlink.h | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.c b/drivers/net/wireless/quantenna/qtnfmac/commands.c index 659e7649fe22..c2f085589f54 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.c +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.c @@ -72,6 +72,8 @@ static int qtnf_cmd_resp_result_decode(enum qlink_cmd_result qcode) return -EADDRINUSE; case QLINK_CMD_RESULT_EADDRNOTAVAIL: return -EADDRNOTAVAIL; + case QLINK_CMD_RESULT_EBUSY: + return -EBUSY; default: return -EFAULT; } diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink.h b/drivers/net/wireless/quantenna/qtnfmac/qlink.h index 8d62addea895..f9c7f87afaf8 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink.h @@ -733,6 +733,7 @@ enum qlink_cmd_result { QLINK_CMD_RESULT_EALREADY, QLINK_CMD_RESULT_EADDRINUSE, QLINK_CMD_RESULT_EADDRNOTAVAIL, + QLINK_CMD_RESULT_EBUSY, }; /** From patchwork Mon Jan 14 09:39:36 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761783 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-2.web.codeaurora.org (Postfix) with ESMTP id 7990C6C2 for ; Mon, 14 Jan 2019 09:40:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6C8EC28A78 for ; Mon, 14 Jan 2019 09:40:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6B0E128AE7; Mon, 14 Jan 2019 09:40:37 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 029B628AD3 for ; Mon, 14 Jan 2019 09:40:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726534AbfANJkg (ORCPT ); Mon, 14 Jan 2019 04:40:36 -0500 Received: from mail-eopbgr730065.outbound.protection.outlook.com ([40.107.73.65]:18944 "EHLO NAM05-DM3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726064AbfANJkf (ORCPT ); Mon, 14 Jan 2019 04:40:35 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Vu2gT5MdPwJszjH78lhun6kjZQjTZJCXGV3b/NvrdxI=; b=CuE5fdhJvQfgSuxZHWJo0DCdaKX3+jU+ijkgpYuPuY6PCFl0Si0T9EUcUYBPIWUX+ng85x5tXkSsNcy/AQjADecTaUgzCWRK+13741PyfY2VXkyikagQFMxB2xF6I1NzYEg1SVR9tQmeqC1QJdqNbWjFWLpuxKK/RU50Dq8Tg40= Received: from BL0PR05MB5124.namprd05.prod.outlook.com (20.177.241.219) by BL0PR05MB5572.namprd05.prod.outlook.com (10.167.240.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:40:25 +0000 Received: from BL0PR05MB5124.namprd05.prod.outlook.com ([fe80::7d09:3e9b:cc44:74eb]) by BL0PR05MB5124.namprd05.prod.outlook.com ([fe80::7d09:3e9b:cc44:74eb%5]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:40:25 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB5838.namprd05.prod.outlook.com (20.177.255.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:37 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:37 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 2/9] qtnfmac: fix INTx interrupt handling Thread-Topic: [PATCH v2 2/9] qtnfmac: fix INTx interrupt handling Thread-Index: AQHUq+0QOFED6no0FUSLhZdFY0oslw== Date: Mon, 14 Jan 2019 09:39:36 +0000 Message-ID: <20190114093925.9061-3-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BL0PR05MB5572;6:bGkZQkwqPVT1rO+nD/U9n85EqwEh6vVPfpma1NiX6jVIrNldLuZPvNYLjaU50x64y2dq4Yvq/d0MM4vFVL2yM8MwlcXayofJDa5Ofqf7b4pL+7/y5/PBlT7G5I9jsde+nPpFsUnsG0MGEcrQGksUt6wsP3QrpbJYIK7Q92zuU/A/+nPnMraXOflxbqjrdF8jDazqwpAZA4mqzhSVUXSMONTbkueY6QApVN7YTfaGR0j1YSKyzyaiibn/sq39ss8s3x0SP0FNTPSWKcpJNkUUBNu5GkTN0++Y9+limhI0b6QU8axwauzZNoiwAtlQN1iNSbtMjKdxl9tFNtRLw+mxVSly+UM29hKXOVzRKHds2y5LvfQGq2c0zRfsrgH+UxN7GD7+Qb2FtHpxJJDaNHVfqlVnFEtDnWAZcbd15qkzjrym49ycjtRvPDQNK1NxRgW8Ogtb1GU+WO5YbSMY1Qy+gw==;5:07nx6vSZGRg51agJJgVwzKqOMR9/IgOZKgX/EWC+iVXs5SxeObzcTW/rHK1pPF/Da1JLrWsVmU20tq3xnniPPa4rPGOtbIOOheT1IpRoR7KstxDWZAAIvrhxjPlqh5EF7UAxtwQ0/TRPerpyMsPq0GnoOUrGLVsl1SJdnRgeGvkxinbMX9H0pzPy5DkAjojaUNmGEKVHMsxkpEAluHtEQw==;7:6n86QMcr/5dGVpHod39QJNUp0M3auMqIjS+p/BSI25F5xShBwWbppygCTV7VTYrin74YHuqx6A/9x2Mwas3ojQvIKgBmO5CZadhwnwTcAMCrxd5KB1uG+RkSevSj/OtxrDQ1+WLeEnUMekjABsCN3w== x-ms-office365-filtering-correlation-id: c2dcfc56-f2e1-461c-6dd0-08d67a043284 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600109)(711020)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB5838; x-ms-traffictypediagnostic: SN6PR05MB5838:|BL0PR05MB5572: x-moderation-data: 1/14/2019 9:40:23 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(366004)(199004)(189003)(105586002)(106356001)(2906002)(2351001)(6116002)(3846002)(36756003)(1076003)(498600001)(86362001)(14454004)(6916009)(103116003)(71200400001)(71190400001)(5640700003)(6486002)(6436002)(66066001)(5660300001)(26005)(186003)(97736004)(68736007)(7736002)(81156014)(8936002)(81166006)(11346002)(476003)(436003)(446003)(99286004)(2501003)(486006)(52116002)(305945005)(76176011)(256004)(107886003)(4326008)(6512007)(102836004)(386003)(6506007)(53936002)(25786009)(2616005)(8676002)(54906003);DIR:OUT;SFP:1101;SCL:1;SRVR:BL0PR05MB5572;H:BL0PR05MB5124.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: kLHkoQtwEb9sTYt82zbXAePx7WylIRRIPXHxvUsE+pWZIqbTou9ZFe2BhDIyhnzPlYGZV81e57nORl5N0Qx324fCIbduDp9cIkZaohMf9WdZkHMS8NLx4+jV6WeYrbIfH8q64l914hLAJa0cnErql/Roh0fOVx1rpPNKO9AkBaVWTAbSVxF0OJWOl2lTl8kQbNul5QzKHsEPeRpy2FBxw424rxUPPtFI+1h17KTEufWZ6gl1uBzmd6LiVCYu4NWlVfmekLaBABnSfTyeZRx8RI0ASAThm0WsaoeYOSaCac7BX6o6o5QNSG6Noadvp19w8CbCJUoRc8TfFFAfJRlBHVUQDs5mnhzyqpsaEZkEOFd6YZOx9KAMQX8rrax8CvsOuyxcpxM+bRi8VqOBbmBrW0OCo/b3JNzomoBqBqYBSLY= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: c2dcfc56-f2e1-461c-6dd0-08d67a043284 X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:25.7398 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR05MB5572 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 In the current implementation INTx interrupt is deasserted after the control path processing. However this may lead to missed interrupts from the wireless card. For instance, this may happen as a result of control path activity, when another interrupt arrives before INTx is deasserted. Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c b/drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c index 598edb814421..cbcda57105f3 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c +++ b/drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c @@ -559,6 +559,9 @@ static irqreturn_t qtnf_pcie_topaz_interrupt(int irq, void *data) if (!priv->msi_enabled && !qtnf_topaz_intx_asserted(ts)) return IRQ_NONE; + if (!priv->msi_enabled) + qtnf_deassert_intx(ts); + priv->pcie_irq_count++; qtnf_shm_ipc_irq_handler(&priv->shm_ipc_ep_in); @@ -571,9 +574,6 @@ static irqreturn_t qtnf_pcie_topaz_interrupt(int irq, void *data) tasklet_hi_schedule(&priv->reclaim_tq); - if (!priv->msi_enabled) - qtnf_deassert_intx(ts); - return IRQ_HANDLED; } From patchwork Mon Jan 14 09:39:38 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761785 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-2.web.codeaurora.org (Postfix) with ESMTP id ECACF13B5 for ; Mon, 14 Jan 2019 09:40:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DFA9A28AD3 for ; Mon, 14 Jan 2019 09:40:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D442828AD2; Mon, 14 Jan 2019 09:40:50 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 293CA28AF3 for ; Mon, 14 Jan 2019 09:40:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726549AbfANJkt (ORCPT ); Mon, 14 Jan 2019 04:40:49 -0500 Received: from mail-eopbgr790070.outbound.protection.outlook.com ([40.107.79.70]:43488 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726064AbfANJkt (ORCPT ); Mon, 14 Jan 2019 04:40:49 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zeHCEWSeIcnffZU20VFfQmQHKR/Jac8Ua7kfYOL3Owc=; b=TsAnEBE/ZEFCZGlhokdyRhbBrH0/1CiroAWFmifNC0sjaE1zS264s+TEAWDwvFxoK6WwLBtWhzVdt9E0RJTCoejLIEpX16BKOZp2QhI0T4jMQdzznJG8ahMc8itOXEygUJYjI+oonu0aozFD7PNY0uyizhNJrtbvay7q1hVzuU4= Received: from DM6PR05MB4956.namprd05.prod.outlook.com (20.177.221.139) by DM6PR05MB6364.namprd05.prod.outlook.com (20.178.224.203) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.16; Mon, 14 Jan 2019 09:40:39 +0000 Received: from DM6PR05MB4956.namprd05.prod.outlook.com ([fe80::bcdf:d16c:dcc5:524f]) by DM6PR05MB4956.namprd05.prod.outlook.com ([fe80::bcdf:d16c:dcc5:524f%5]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:40:39 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB5838.namprd05.prod.outlook.com (20.177.255.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:39 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:39 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 3/9] qtnfmac: add support for 4addr mode Thread-Topic: [PATCH v2 3/9] qtnfmac: add support for 4addr mode Thread-Index: AQHUq+0Rf7L9K+H2OUK3+C6FxJ5odA== Date: Mon, 14 Jan 2019 09:39:38 +0000 Message-ID: <20190114093925.9061-4-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM6PR05MB6364;6:elckr+ZEbma1Z5UuPzZQeD53VCymo4iy+DDxXqL3eWQ5ddtaCWbn8x6OGEdAg/SitlN7YyBskAY15e34CPRIo0IewdoKC6GDiQ1tnnzvPRkBGyfWF9uLBJ39TiwtaHf0SRC4sgHNoxa2P7UQb9ieBJt9e0HoUcq1jxg53iqWrZIVWysEkAB1Be7kOz9GRi6r5CiH7w4O6is3Olw2PVuxY8vjB/xbtLb5bApzvyBsWvE5UUeVdNm/g3W0NQvTO7O1B9syboiS9E0y0B3XDn0s3Ift+dra9BX9tiYFZSL3UzwulbEsfhwh7LzUIzCrIGWLP1lY8ymdx36CpSbaQ803bhGpa8DkfuQkNGnZhdyUMltBso4i8PoGsGacSOUgTKwzJTjun5RXK5ztAnfD+IKDbbOKR1OTyGp0VeKEUh+bjMWRTFLjhFGfgw9LDXiEJeSQx3F1mWtc/CWFyr46ZHMWAA==;5:U2YgQt6PSQ1nr7pjTTvT4p6gl6kX5R7zMxcC5ThMAsRvVe+SjZEKCCjAJLsbUPH+Z+OoYpUw91rw+O7/tG5JCPnumid0PFIJGJX3cxmqcLwY7f4vfp+d/TH9ur9KNtQKQ1ncoVSSgNyWAI+3w5trCMqwdKMi59tZYtSuskUJJu5+9vuh2QQu4XZ6J/h8MvzLrDLIv0fSEc/8gNcZLy9QIg==;7:3v9DSe8M/BTOvrSEHyWRn00kJgd23THKbj9HaiH94rrCKm6P6yQFWckfyBOSv5/Np4KmFdJo1FZL7Cl32Nc/EaOkUyWU1w/rrUVLjgIKGkyXm//jdMdXr0aP3JIdOWyIf5+uzd14/YBvhYxl67V88Q== x-ms-office365-filtering-correlation-id: 8ac94d48-b69f-48ac-fafa-08d67a0433aa x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600109)(711020)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB5838; x-ms-traffictypediagnostic: SN6PR05MB5838:|DM6PR05MB6364: x-moderation-data: 1/14/2019 9:40:37 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(366004)(376002)(396003)(136003)(346002)(39840400004)(189003)(199004)(305945005)(97736004)(486006)(6506007)(6436002)(66066001)(1076003)(2351001)(8676002)(5640700003)(5660300001)(4326008)(256004)(436003)(478600001)(7736002)(99286004)(102836004)(5024004)(14444005)(386003)(25786009)(68736007)(26005)(6916009)(36756003)(52116002)(71200400001)(71190400001)(6486002)(2906002)(76176011)(103116003)(81156014)(2616005)(316002)(3846002)(186003)(6116002)(446003)(11346002)(476003)(81166006)(14454004)(2501003)(54906003)(6512007)(107886003)(86362001)(53936002)(105586002)(8936002)(106356001);DIR:OUT;SFP:1101;SCL:1;SRVR:DM6PR05MB6364;H:DM6PR05MB4956.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: lzc0UTlU1aVzjvcrpFDmYVM+o9S/G9/M4O5BPuaE3qcOsbFJlJDOynH0Yyc5LuCAW+iLR7g1g73zFrOrF/pewX/Sn5lT6r14339ZuRLVqxFaPcb+sV//bRYA+abgi1tbJnI1v0od6nY0R7eztcJkDztGtavG8rH20ocC5ArW7B3z/CszPbkH9EzMPni+gxIafQS/PFh4Donyh6/mo0nBDW9ZobEXLpz4PJA9iWDafP0mWeEysUiIILvM0ectTZtuRj5IPU+k2CkKy04V6at/ktEedMJkE0g2yYqoSpxUViUf/PvzAT7+Ipo+DwVdCm5pHf9ocovqCZoJVCBXJWDRhVtgJl54bLBAGBi/hUcQ72TMY5viSZt/bpAxAdSAw+eZrdD7Kl/kwUH93GyqZ0KTU3ZjrtrBYwT567hyegY+M8o= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8ac94d48-b69f-48ac-fafa-08d67a0433aa X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:39.4451 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR05MB6364 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 Advertise WIPHY_FLAG_4ADDR_STATION capability to wireless core. Send use4addr interface change flag to firmware in change_virtual_intf cfg80211 callback. In order to enable adding wireless station interface to bridge one should turn on 4addr mode using the following command: $ iw dev wlan0 set 4addr on $ brctl addif br0 wlan0 If this commands succeeds, then interface can be added to bridge. Note that when wireless interface is added to bridge, wpa_supplicant should be started with appropriate -b parameter, e.g: $ wpa_supplicant -Dnl80211 -iwlan0 -c/path/to/wpa.conf -b br0 Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/qtnfmac/cfg80211.c | 21 +++++++++++++-------- drivers/net/wireless/quantenna/qtnfmac/commands.c | 14 +++++++++----- drivers/net/wireless/quantenna/qtnfmac/commands.h | 6 ++++-- drivers/net/wireless/quantenna/qtnfmac/core.c | 4 +++- drivers/net/wireless/quantenna/qtnfmac/qlink.h | 3 ++- 5 files changed, 31 insertions(+), 17 deletions(-) diff --git a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c index 51b33ec78fac..a43f8120df3c 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c +++ b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c @@ -122,7 +122,8 @@ qtnf_change_virtual_intf(struct wiphy *wiphy, struct vif_params *params) { struct qtnf_vif *vif = qtnf_netdev_get_priv(dev); - u8 *mac_addr; + u8 *mac_addr = NULL; + int use4addr = 0; int ret; ret = qtnf_validate_iface_combinations(wiphy, vif, type); @@ -132,14 +133,14 @@ qtnf_change_virtual_intf(struct wiphy *wiphy, return ret; } - if (params) + if (params) { mac_addr = params->macaddr; - else - mac_addr = NULL; + use4addr = params->use_4addr; + } qtnf_scan_done(vif->mac, true); - ret = qtnf_cmd_send_change_intf_type(vif, type, mac_addr); + ret = qtnf_cmd_send_change_intf_type(vif, type, use4addr, mac_addr); if (ret) { pr_err("VIF%u.%u: failed to change type to %d\n", vif->mac->macid, vif->vifid, type); @@ -190,6 +191,7 @@ static struct wireless_dev *qtnf_add_virtual_intf(struct wiphy *wiphy, struct qtnf_wmac *mac; struct qtnf_vif *vif; u8 *mac_addr = NULL; + int use4addr = 0; int ret; mac = wiphy_priv(wiphy); @@ -225,10 +227,12 @@ static struct wireless_dev *qtnf_add_virtual_intf(struct wiphy *wiphy, return ERR_PTR(-ENOTSUPP); } - if (params) + if (params) { mac_addr = params->macaddr; + use4addr = params->use_4addr; + } - ret = qtnf_cmd_send_add_intf(vif, type, mac_addr); + ret = qtnf_cmd_send_add_intf(vif, type, use4addr, mac_addr); if (ret) { pr_err("VIF%u.%u: failed to add VIF %pM\n", mac->macid, vif->vifid, mac_addr); @@ -1107,7 +1111,8 @@ int qtnf_wiphy_register(struct qtnf_hw_info *hw_info, struct qtnf_wmac *mac) wiphy->flags |= WIPHY_FLAG_HAVE_AP_SME | WIPHY_FLAG_AP_PROBE_RESP_OFFLOAD | WIPHY_FLAG_AP_UAPSD | - WIPHY_FLAG_HAS_CHANNEL_SWITCH; + WIPHY_FLAG_HAS_CHANNEL_SWITCH | + WIPHY_FLAG_4ADDR_STATION; wiphy->flags &= ~WIPHY_FLAG_PS_ON_BY_DEFAULT; if (hw_info->hw_capab & QLINK_HW_CAPAB_DFS_OFFLOAD) diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.c b/drivers/net/wireless/quantenna/qtnfmac/commands.c index c2f085589f54..0748a756cc1c 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.c +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.c @@ -734,6 +734,7 @@ int qtnf_cmd_get_sta_info(struct qtnf_vif *vif, const u8 *sta_mac, static int qtnf_cmd_send_add_change_intf(struct qtnf_vif *vif, enum nl80211_iftype iftype, + int use4addr, u8 *mac_addr, enum qlink_cmd_type cmd_type) { @@ -751,6 +752,7 @@ static int qtnf_cmd_send_add_change_intf(struct qtnf_vif *vif, qtnf_bus_lock(vif->mac->bus); cmd = (struct qlink_cmd_manage_intf *)cmd_skb->data; + cmd->intf_info.use4addr = use4addr; switch (iftype) { case NL80211_IFTYPE_AP: @@ -786,17 +788,19 @@ static int qtnf_cmd_send_add_change_intf(struct qtnf_vif *vif, return ret; } -int qtnf_cmd_send_add_intf(struct qtnf_vif *vif, - enum nl80211_iftype iftype, u8 *mac_addr) +int qtnf_cmd_send_add_intf(struct qtnf_vif *vif, enum nl80211_iftype iftype, + int use4addr, u8 *mac_addr) { - return qtnf_cmd_send_add_change_intf(vif, iftype, mac_addr, + return qtnf_cmd_send_add_change_intf(vif, iftype, use4addr, mac_addr, QLINK_CMD_ADD_INTF); } int qtnf_cmd_send_change_intf_type(struct qtnf_vif *vif, - enum nl80211_iftype iftype, u8 *mac_addr) + enum nl80211_iftype iftype, + int use4addr, + u8 *mac_addr) { - return qtnf_cmd_send_add_change_intf(vif, iftype, mac_addr, + return qtnf_cmd_send_add_change_intf(vif, iftype, use4addr, mac_addr, QLINK_CMD_CHANGE_INTF); } diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.h b/drivers/net/wireless/quantenna/qtnfmac/commands.h index 1ac41156c192..1c25e7905e9a 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.h +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.h @@ -26,9 +26,11 @@ void qtnf_cmd_send_deinit_fw(struct qtnf_bus *bus); int qtnf_cmd_get_hw_info(struct qtnf_bus *bus); int qtnf_cmd_get_mac_info(struct qtnf_wmac *mac); int qtnf_cmd_send_add_intf(struct qtnf_vif *vif, enum nl80211_iftype iftype, - u8 *mac_addr); + int use4addr, u8 *mac_addr); int qtnf_cmd_send_change_intf_type(struct qtnf_vif *vif, - enum nl80211_iftype iftype, u8 *mac_addr); + enum nl80211_iftype iftype, + int use4addr, + u8 *mac_addr); int qtnf_cmd_send_del_intf(struct qtnf_vif *vif); int qtnf_cmd_band_info_get(struct qtnf_wmac *mac, struct ieee80211_supported_band *band); diff --git a/drivers/net/wireless/quantenna/qtnfmac/core.c b/drivers/net/wireless/quantenna/qtnfmac/core.c index 5d18a4a917c9..29258acfa8dc 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/core.c +++ b/drivers/net/wireless/quantenna/qtnfmac/core.c @@ -195,6 +195,7 @@ static int qtnf_netdev_set_mac_address(struct net_device *ndev, void *addr) qtnf_scan_done(vif->mac, true); ret = qtnf_cmd_send_change_intf_type(vif, vif->wdev.iftype, + vif->wdev.use_4addr, sa->sa_data); if (ret) @@ -545,7 +546,8 @@ static int qtnf_core_mac_attach(struct qtnf_bus *bus, unsigned int macid) goto error; } - ret = qtnf_cmd_send_add_intf(vif, vif->wdev.iftype, vif->mac_addr); + ret = qtnf_cmd_send_add_intf(vif, vif->wdev.iftype, + vif->wdev.use_4addr, vif->mac_addr); if (ret) { pr_err("MAC%u: failed to add VIF\n", macid); goto error; diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink.h b/drivers/net/wireless/quantenna/qtnfmac/qlink.h index f9c7f87afaf8..a78cb9e05068 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink.h @@ -105,7 +105,8 @@ struct qlink_intf_info { __le16 if_type; __le16 vlanid; u8 mac_addr[ETH_ALEN]; - u8 rsvd[2]; + u8 use4addr; + u8 rsvd[1]; } __packed; enum qlink_sta_flags { From patchwork Mon Jan 14 09:39:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761787 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-2.web.codeaurora.org (Postfix) with ESMTP id 62CB76C2 for ; Mon, 14 Jan 2019 09:40:55 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 554FD28AB3 for ; Mon, 14 Jan 2019 09:40:55 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 49E1728AF8; Mon, 14 Jan 2019 09:40:55 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 BEF1528AC8 for ; Mon, 14 Jan 2019 09:40:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726563AbfANJky (ORCPT ); Mon, 14 Jan 2019 04:40:54 -0500 Received: from mail-eopbgr690063.outbound.protection.outlook.com ([40.107.69.63]:62152 "EHLO NAM04-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726553AbfANJkx (ORCPT ); Mon, 14 Jan 2019 04:40:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=QEoLJJjeET7YVkkVmrU75AfN8ifqCZbwbdPtWBe7uQA=; b=kk/izEhxGiPZrDXMsOY3q6ffoLeEqPLyWYeX8J0gezAB8HJ8j8uzGap9mJvpfr1YOPTKNrmW1FNVkweHl0JgghXJZ3hj8kMoPMbpOJXUVZcqO3/ygY2i12NpODW2f5mUYLcODgDNjCfx9YIvl/8sQFZlzm5SeFsm6aywk2JxuKQ= Received: from BYAPR05MB5352.namprd05.prod.outlook.com (20.177.127.161) by BYAPR05MB6631.namprd05.prod.outlook.com (20.179.60.205) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1516.6; Mon, 14 Jan 2019 09:40:44 +0000 Received: from BYAPR05MB5352.namprd05.prod.outlook.com ([fe80::7923:9302:1418:e431]) by BYAPR05MB5352.namprd05.prod.outlook.com ([fe80::7923:9302:1418:e431%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:40:44 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB4719.namprd05.prod.outlook.com (52.135.114.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:41 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:41 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 4/9] qtnfmac: switch to 32bit values for RTS/FRAG thresholds Thread-Topic: [PATCH v2 4/9] qtnfmac: switch to 32bit values for RTS/FRAG thresholds Thread-Index: AQHUq+0S3v7o9/ZvQEWFbYwTc8bZSA== Date: Mon, 14 Jan 2019 09:39:40 +0000 Message-ID: <20190114093925.9061-5-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BYAPR05MB6631;6:DAEa5WijXChE7y+X/N4nQOmRFVB5VIzf7q+tk1/NE+rpaF+nD5gNJm3JRx+SqLiEpr6XNEDPVxYF8LnpcGmKTnx6f27CPzv1HmIAM0K0nNmRM2mmpYS3dTSbpweUf0msTal7SmBNiRHLci2R9oPNqaSJRPKx/IqCbOsh8CJgboVHE3iSVJaowXqZpZ7D8jAJQtSBynnS4w8zC1//kDfXqpRx+xW7Kd7rsix1CC40iYHTTYuIdnBKvn3u8VPCJToB9wU+4PgdTb7mi1+BzW8SbipXSHotQE6UrgFZHL3cOp5tREY4ZSQApoIpVSFDlTGXx8OR6F2VsJSbUKAkN6NSsHUpUNbDwQim09UUQIf80G6SjWNDDnPt6jLvT2Y0ruqSdis2JBjzNBQjsUM/w8D8lb48SVRBKF/pKPfi57ai4wET4hfNsUYhS5d7Y6cShlFXCDGtd+AhND50wNXYyloPDg==;5:GaeaX+0BSV6cPBp+opwy9X0gap2MpE+zGGlr5ExlWUM9J5mmzS5zgDQp7wavFcljDy1upz9LulW8BlL7uXmZIm8dJeE/HVGrpgK5wMN8lh4J5H3Zizfqgdk/cl9Yydjxl5jAAUrFbMkKKUzorbl9vCmg5KOaQqmKV+AHw3iXSJJwo3EMSV+xlM+5guQqbsLsYvkhiIv8XIsA2fsj9vWq1Q==;7:2teu0wBojy+VlgqsDQ3yCUfkC/t9yyPqPQzp8vJyhI0O5qIOPAlV1rmD4zqmjCiFBNo3QCp8WAwbLdFue1t/fz+2xvi/yH62ApDYdAfxAyqMnm7E9Z7ZSZe4CMN4L8d7CKM5mC9HVcUMgb5tXZbdyQ== x-ms-office365-filtering-correlation-id: 7edf2816-7a7b-4d25-74db-08d67a0434db x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(5600109)(711020)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB4719; x-ms-traffictypediagnostic: SN6PR05MB4719:|BYAPR05MB6631: authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-moderation-data: 1/14/2019 9:40:41 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(366004)(376002)(136003)(346002)(396003)(39840400004)(189003)(199004)(14454004)(14444005)(7736002)(2501003)(8936002)(2616005)(256004)(6916009)(107886003)(11346002)(3846002)(66066001)(6436002)(97736004)(103116003)(476003)(4326008)(446003)(81166006)(53936002)(6486002)(486006)(6116002)(36756003)(8676002)(81156014)(305945005)(5660300001)(6512007)(76176011)(52116002)(186003)(26005)(25786009)(54906003)(2906002)(105586002)(99286004)(575784001)(68736007)(5640700003)(316002)(6506007)(386003)(86362001)(106356001)(71190400001)(102836004)(2351001)(478600001)(71200400001)(436003)(1076003);DIR:OUT;SFP:1101;SCL:1;SRVR:BYAPR05MB6631;H:BYAPR05MB5352.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: fgpJWtkxX3Ffv0hFATi2crmRYghXXXy53l7NPsGL6jJOveu2/56k8jL+wBeabATUqZadksm2NI3wEAXeNfApCaUFcGnO9yT90pwcc/V75O8h0OH6toh13CJijW5xRJCIdTvDdenN7eugwksr8fjU6xKyW7miCAtpyTD0oh5dEEAxUAxgbCKPXGcF8xUbZTMd4oea6PTRWwiGRl4Jg5mlEjYCJo+sifE5Bzur5kpA+W2U0Ex4vvVFM6c0iHX+CGoXpZQi6BEtEywZqfkaPNphX1FUYTmRuDF1xWqphZsPKuFlNtmEabTj+f2ob8D7+8v7ObKERT+0845HYPzmNZsZlGPOdAjel8MfwqKAh5DRVAeOUT+IahQKS8K2FmIG/RUbRJjYKqlCXFz/mV3uMHdzdjInFWDT8kSb8fVo1iitC9o= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7edf2816-7a7b-4d25-74db-08d67a0434db X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:44.3282 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR05MB6631 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 Host wireless stack uses u32 type for RTS/FRAG threshold values. Switch to u32 in driver: pass u32 values to firmware and let firmware properly adapt these values according to its internal representation. Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/qtnfmac/commands.c | 8 ++++---- drivers/net/wireless/quantenna/qtnfmac/qlink.h | 4 ++-- drivers/net/wireless/quantenna/qtnfmac/qlink_util.h | 11 +++++++++++ 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.c b/drivers/net/wireless/quantenna/qtnfmac/commands.c index 0748a756cc1c..66cb05dfdba5 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.c +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.c @@ -1564,11 +1564,11 @@ static int qtnf_cmd_resp_proc_phy_params(struct qtnf_wmac *mac, switch (tlv_type) { case QTN_TLV_ID_FRAG_THRESH: phy_thr = (void *)tlv; - mac_info->frag_thr = (u32)le16_to_cpu(phy_thr->thr); + mac_info->frag_thr = le32_to_cpu(phy_thr->thr); break; case QTN_TLV_ID_RTS_THRESH: phy_thr = (void *)tlv; - mac_info->rts_thr = (u32)le16_to_cpu(phy_thr->thr); + mac_info->rts_thr = le32_to_cpu(phy_thr->thr); break; case QTN_TLV_ID_SRETRY_LIMIT: limit = (void *)tlv; @@ -1816,10 +1816,10 @@ int qtnf_cmd_send_update_phy_params(struct qtnf_wmac *mac, u32 changed) qtnf_bus_lock(mac->bus); if (changed & WIPHY_PARAM_FRAG_THRESHOLD) - qtnf_cmd_skb_put_tlv_u16(cmd_skb, QTN_TLV_ID_FRAG_THRESH, + qtnf_cmd_skb_put_tlv_u32(cmd_skb, QTN_TLV_ID_FRAG_THRESH, wiphy->frag_threshold); if (changed & WIPHY_PARAM_RTS_THRESHOLD) - qtnf_cmd_skb_put_tlv_u16(cmd_skb, QTN_TLV_ID_RTS_THRESH, + qtnf_cmd_skb_put_tlv_u32(cmd_skb, QTN_TLV_ID_RTS_THRESH, wiphy->rts_threshold); if (changed & WIPHY_PARAM_COVERAGE_CLASS) qtnf_cmd_skb_put_tlv_u8(cmd_skb, QTN_TLV_ID_COVERAGE_CLASS, diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink.h b/drivers/net/wireless/quantenna/qtnfmac/qlink.h index a78cb9e05068..ace52e9d421d 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink.h @@ -19,7 +19,7 @@ #include -#define QLINK_PROTO_VER 11 +#define QLINK_PROTO_VER 12 #define QLINK_MACID_RSVD 0xFF #define QLINK_VIFID_RSVD 0xFF @@ -1184,7 +1184,7 @@ struct qlink_iface_limit_record { struct qlink_tlv_frag_rts_thr { struct qlink_tlv_hdr hdr; - __le16 thr; + __le32 thr; } __packed; struct qlink_tlv_rlimit { diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h b/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h index 960d5d97492f..fc87827cb49c 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h @@ -69,6 +69,17 @@ static inline void qtnf_cmd_skb_put_tlv_u16(struct sk_buff *skb, memcpy(hdr->val, &tmp, sizeof(tmp)); } +static inline void qtnf_cmd_skb_put_tlv_u32(struct sk_buff *skb, + u16 tlv_id, u32 value) +{ + struct qlink_tlv_hdr *hdr = skb_put(skb, sizeof(*hdr) + sizeof(value)); + __le32 tmp = cpu_to_le32(value); + + hdr->type = cpu_to_le16(tlv_id); + hdr->len = cpu_to_le16(sizeof(value)); + memcpy(hdr->val, &tmp, sizeof(tmp)); +} + u16 qlink_iface_type_to_nl_mask(u16 qlink_type); u8 qlink_chan_width_mask_to_nl(u16 qlink_mask); void qlink_chandef_q2cfg(struct wiphy *wiphy, From patchwork Mon Jan 14 09:39:42 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761789 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-2.web.codeaurora.org (Postfix) with ESMTP id 8B58B6C2 for ; Mon, 14 Jan 2019 09:40:58 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7E6E128AF4 for ; Mon, 14 Jan 2019 09:40:58 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 726C628AD3; Mon, 14 Jan 2019 09:40:58 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 1B9C828AD2 for ; Mon, 14 Jan 2019 09:40:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726554AbfANJk5 (ORCPT ); Mon, 14 Jan 2019 04:40:57 -0500 Received: from mail-eopbgr680088.outbound.protection.outlook.com ([40.107.68.88]:11680 "EHLO NAM04-BN3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726449AbfANJk5 (ORCPT ); Mon, 14 Jan 2019 04:40:57 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WMfjMBWZmTnRgh/pwL6kHuAhZWrNwSBQT4sJ7gllZRE=; b=osXvXNXFbX8f5IXWagXhV74go/tpxQkOeBibrtLoJG2c4O0RCrXN/IV8Qt4TXZT0I9W2Ctehs/OSekUjXHwnkpskyCKxPN0tyBWa4MFERqj4FzBrO/ZXZdJ248GUlWgBOJp2ypI3+1d9USbqi+6V6mmYZev48W8Ytmc/ugCLqMg= Received: from DM6PR05MB6298.namprd05.prod.outlook.com (20.178.27.207) by DM6PR05MB6683.namprd05.prod.outlook.com (20.178.228.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.19; Mon, 14 Jan 2019 09:40:46 +0000 Received: from DM6PR05MB6298.namprd05.prod.outlook.com ([fe80::2884:6b82:d80a:1be9]) by DM6PR05MB6298.namprd05.prod.outlook.com ([fe80::2884:6b82:d80a:1be9%4]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:40:46 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB4719.namprd05.prod.outlook.com (52.135.114.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:42 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:42 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 5/9] qtnfmac: do not reject retry changes in driver Thread-Topic: [PATCH v2 5/9] qtnfmac: do not reject retry changes in driver Thread-Index: AQHUq+0TLO5F9uwFqk+FFHSXxW2ySw== Date: Mon, 14 Jan 2019 09:39:42 +0000 Message-ID: <20190114093925.9061-6-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM6PR05MB6683;6:8OACE4sienw8J8dpGKdN1MNW24oCFNxWYeOE5niYrdICkQzcyY/rqViy7SD8sstOFRr/qmR+NC7S+/kELBhQ1fI3THODszSJC98IfW0O1koo8yLgR0vtb9/NOQt82L5PLKmHFfi8hncHj9luqw/lfyAAGx9EiNfj/YdkYGyOIkEKHvozvUwQrHAqrmkXZJ+Qf5t+sPUrGMLE9f3AFpHfJDx/13Rfv5x+3zPzHQaNvBMZfZD+1DbWyf8CSF6NWhlLcnRmmaff1eS+8aPtnOlfrvUR2z2SnPo7uBImRfO5rFV8IzeT8GEKG4SzdGdndjKHr882DFKkuG8aY5yM8yBFeABY9Lv3h8F+1Do1eXTHazGBJQmOYovqR9KSB9KHC1U/9hYNbib4ho030WZr8eSpGvPaIEjUUbjbsfVn/qcqEl7LpcU5JXQM7+nE2RVjbdQZqo1PUl+H9gRoHwWSXBT7oQ==;5:Vysrw5l7CQfL2ElGF5w0Y4//Tx/JgnV4WbQ6PmEC586pCpzxKKVR/CLIdhQiJB1ECR/BTr8Tl97FKIezFttmDTmjvnlafpQ1ahTqz9Qd4OxTRtNnHIrUfp2PhbpW/fbn5I69Jfxky0iEsglzIz8hnoDIZ9V4gdJ9U5Uztsiggcnb1HEZpo5vsvzXF6hfp6fRFemjqeEJrhBHyH/Z7HYpsg==;7:xNZkxD2KnmMwYi1c7Ai8mD/mj8ft0oDyAUfH14kSZe4Als44f+atDTqhKQVA7EFyfbMqFY/jd1pm2+PWHpIvbzwH3/Vos0PWN8LW+GLZRSka8Hh3YTHDQ0aPLtrPgbq+uDhLlIj5DENt9+3JbixuKw== x-ms-office365-filtering-correlation-id: 3c21d404-75c0-412b-7749-08d67a043602 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(5600109)(711020)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB4719; x-ms-traffictypediagnostic: SN6PR05MB4719:|DM6PR05MB6683: authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-moderation-data: 1/14/2019 9:40:44 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(136003)(396003)(376002)(346002)(39840400004)(366004)(189003)(199004)(1076003)(25786009)(316002)(6436002)(5660300001)(8676002)(5640700003)(81156014)(81166006)(76176011)(36756003)(14454004)(6916009)(102836004)(6506007)(386003)(2906002)(52116002)(6486002)(71200400001)(71190400001)(97736004)(436003)(54906003)(6512007)(4326008)(476003)(11346002)(105586002)(486006)(2616005)(2351001)(68736007)(446003)(103116003)(478600001)(106356001)(575784001)(86362001)(66066001)(2501003)(99286004)(6116002)(305945005)(8936002)(186003)(26005)(3846002)(7736002)(53936002)(14444005)(256004)(107886003);DIR:OUT;SFP:1101;SCL:1;SRVR:DM6PR05MB6683;H:DM6PR05MB6298.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: udxxnJdNlQji5q/1vfiyQxLJjH64ys3mBfGjzdT1Ce4lmP3UXl6HGnRwLJqSru8wQRxX1+JYTdtb/sI5SunrnhyQAQq3OkwmLvSQB1qM1yYmvW3U7iNJs0uxf/XQcBhFOtyQAEHvUH534m964aSKAfiCJCCSN+UUT33u1I6LtyMzyxPwLFH+E7WrZb+kR3EcQ9kAbfnizm/yi9v8k/RcDvzFSW6A57CKu+C3Szn5lgvB302BWdx6iP3q0FtQPZKjz1ImgFO+2Bo9stVIEGp0D1hMs0Q+u3+ur2vcFShJJ8gf7yYGOR0DKMvxDcfNLx/2a9Qyyxdaveh5OY0BCWjILi12qgdkLv0/qRdHaRwkvX0P4M9MbRLPyzbUSKimdh2on4JGBrKQ9qvj1ePzQx4CdTvZ1H1EqjflO1Af8KkLnE4= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3c21d404-75c0-412b-7749-08d67a043602 X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:46.8663 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR05MB6683 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 Do not reject RETRY changes in driver. This decision should belong to firmware. Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/qtnfmac/cfg80211.c | 5 ----- drivers/net/wireless/quantenna/qtnfmac/commands.c | 8 ++++++++ 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c index a43f8120df3c..1b02096934f8 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c +++ b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c @@ -363,11 +363,6 @@ static int qtnf_set_wiphy_params(struct wiphy *wiphy, u32 changed) return -EFAULT; } - if (changed & (WIPHY_PARAM_RETRY_LONG | WIPHY_PARAM_RETRY_SHORT)) { - pr_err("MAC%u: can't modify retry params\n", mac->macid); - return -EOPNOTSUPP; - } - ret = qtnf_cmd_send_update_phy_params(mac, changed); if (ret) pr_err("MAC%u: failed to update PHY params\n", mac->macid); diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.c b/drivers/net/wireless/quantenna/qtnfmac/commands.c index 66cb05dfdba5..3f0a0b6abf01 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.c +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.c @@ -1825,6 +1825,14 @@ int qtnf_cmd_send_update_phy_params(struct qtnf_wmac *mac, u32 changed) qtnf_cmd_skb_put_tlv_u8(cmd_skb, QTN_TLV_ID_COVERAGE_CLASS, wiphy->coverage_class); + if (changed & WIPHY_PARAM_RETRY_LONG) + qtnf_cmd_skb_put_tlv_u8(cmd_skb, QTN_TLV_ID_LRETRY_LIMIT, + wiphy->retry_long); + + if (changed & WIPHY_PARAM_RETRY_SHORT) + qtnf_cmd_skb_put_tlv_u8(cmd_skb, QTN_TLV_ID_SRETRY_LIMIT, + wiphy->retry_short); + ret = qtnf_cmd_send(mac->bus, cmd_skb); if (ret) goto out; From patchwork Mon Jan 14 09:39:45 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761791 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-2.web.codeaurora.org (Postfix) with ESMTP id 87CC413B5 for ; Mon, 14 Jan 2019 09:41:02 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7654328AB3 for ; Mon, 14 Jan 2019 09:41:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 732DE28AF3; Mon, 14 Jan 2019 09:41:02 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 C5AF428B02 for ; Mon, 14 Jan 2019 09:41:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726064AbfANJlA (ORCPT ); Mon, 14 Jan 2019 04:41:00 -0500 Received: from mail-eopbgr790089.outbound.protection.outlook.com ([40.107.79.89]:22134 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726534AbfANJk7 (ORCPT ); Mon, 14 Jan 2019 04:40:59 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/FifbCwV/SaXGnn4rnwOaTkcN2wD8lrvnS1KlYdtryQ=; b=u3e92MTDe15+uAvYdWLQ7EMWUT5BmXN5szqg11po0iFYPnHI2T4er1wzqu2HUMq7kWtWg37uFp7dOCdXK9QrFG7oQJ1ALudzIUEHWWlp8/FgoCdhxX/+HTpgGyYzrW4XFNdNPN65quBQgV4yWzmtLQka0NP6/cOVQy9370bHNhY= Received: from BYAPR05MB4423.namprd05.prod.outlook.com (52.135.202.161) by BYAPR05MB5782.namprd05.prod.outlook.com (20.178.48.223) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.18; Mon, 14 Jan 2019 09:40:46 +0000 Received: from BYAPR05MB4423.namprd05.prod.outlook.com ([fe80::3158:fd7e:cb38:19d0]) by BYAPR05MB4423.namprd05.prod.outlook.com ([fe80::3158:fd7e:cb38:19d0%2]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:40:46 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB4719.namprd05.prod.outlook.com (52.135.114.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:45 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:45 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 6/9] qtnfmac: convert to SPDX license identifiers Thread-Topic: [PATCH v2 6/9] qtnfmac: convert to SPDX license identifiers Thread-Index: AQHUq+0VJiWGpbm8YUSFxlO1GTcI7g== Date: Mon, 14 Jan 2019 09:39:45 +0000 Message-ID: <20190114093925.9061-7-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BYAPR05MB5782;6:4E8hReGdZv6vOwCvGPDBsSGaH/1mREDWb9AP2P6bZ9ts5Qy/rS037/W+4SjgjKwgkkMpuOYmtXT3TQapYaSJMFsoX91GymG4+06WN7Jm3+IS4VVT8X+eSvFAFnWir1BJPcy4V/bJkX5+JoU8/U6D+kLO8zSx7zm9/YxMIPS66tbDwazYXSod4ItQ6ke/TJQz/nrTcP27wD2YxlsCjcFGtx632M1v8Qn7Km9DlBG/8AL80sRbbZ0htJU1iLk4c8LWYlykZixao6Y37t8fMAkVJnftcZcEE0h570K8XcJnlw+4jNH0QziVQ5J656YtPMqcShN6UGf7PzRotk0leUQWkvfw9j8vYYie4wcczDST+ZAyNUlWVylb1kwyTiaeq1mAqG3FNGVf5dhDb7y6MlqCkD70EAEhvjj0XHlTu6K54ltG6F37AEQ+chsj8LtE5e0+O2CrPmz0Piopfq5SgOE+Ng==;5:oS5AgmUQ0dINpHME+JjjOb82KAX0saSEueSyE2mz+lYoM5bprtwoFWFV0jAxVS5dqTy7LaAT/08jUc65vl/esaHbSsBr0O8NTG+iD8Le0pExoMy4YptQbfXsauORM7JVdoP/4tXCeXlQRNger96ClY+irOZuCf9cMFFe8QldjZb3swHhqFdJGPW2d0E3XmkyCd/R15aHUaGAwH0Yr1zXoQ==;7:d5CMz53sYhwGcjapQcoCC+kIdoQmTGdAuSgITx6o6tvOtUAoVyspfpwCl40wbRl+LEEjRuJEcebtqE6brM58OjMAOlgjY772hCn6FAKwQl07fIUwXZCrkhPq+/0GJ9atMSh0D7WUy2h2cVwIFyFHfg== x-ms-office365-filtering-correlation-id: c2c5d17d-2ad1-4c2d-61fe-08d67a043721 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(5600109)(711020)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB4719; x-ms-traffictypediagnostic: SN6PR05MB4719:|BYAPR05MB5782: authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-moderation-data: 1/14/2019 9:40:45 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(346002)(376002)(366004)(39840400004)(396003)(136003)(199004)(189003)(105586002)(305945005)(8936002)(6916009)(486006)(7736002)(5660300001)(2616005)(81166006)(81156014)(71190400001)(71200400001)(1076003)(30864003)(256004)(11346002)(8676002)(14444005)(446003)(476003)(106356001)(436003)(575784001)(6116002)(68736007)(86362001)(2906002)(186003)(6486002)(3846002)(14454004)(2501003)(107886003)(53936002)(102836004)(52116002)(97736004)(6436002)(54906003)(5640700003)(316002)(26005)(53946003)(76176011)(103116003)(36756003)(25786009)(66066001)(99286004)(478600001)(6512007)(2351001)(4326008)(386003)(6506007)(2004002)(559001)(579004);DIR:OUT;SFP:1101;SCL:1;SRVR:BYAPR05MB5782;H:BYAPR05MB4423.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: T1qaM8DLaEm8K3bcuUjzLgVMDE1ISUedwAOybny5GvdTcuwpS8ml/Y1cFEtbWcU2xFBlHX872k91/FA6resJbwERgwXFzQpr9B59mp2UvVrUVSGUGvy8ye3WRcK+YMHcfl7gCvcNxMdB7E+XXWVFJtcRH/WRl7LTQI4pIqa05RaTJCVsnsl8ER+SdlslggC7wrcs1XF2o0KFHYSs77DPR+JOIiVOuflVExROuzl7r6NNVlyLy7Psma+B7PC8c8uSUdYOa8LS+DHoJe4AuIOGGf+YzaAT/9kEG1A9oOxYFBQofsCYqM/NEEP4R4b/N1mXmB1LxpYvE//+0xSR75ycaG/iyc2Ueg3JNwtUpNOm2C3CQsvJ6SEB6YyVJBEF63DY/stBKlMWh16Qp+uZ8GYA5OqzRgAD3lrSgAiX9CcNKsk= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: c2c5d17d-2ad1-4c2d-61fe-08d67a043721 X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:46.7954 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR05MB5782 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 Replace textual license with SPDX-License-Identifier. Add an SPDX-License-Identifier for the Makefile. Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/Makefile | 1 + drivers/net/wireless/quantenna/qtnfmac/bus.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/cfg80211.c | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/cfg80211.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/commands.c | 16 ++-------------- drivers/net/wireless/quantenna/qtnfmac/commands.h | 16 ++-------------- drivers/net/wireless/quantenna/qtnfmac/core.c | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/core.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/debug.c | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/debug.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/event.c | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/event.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/qlink.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/qlink_util.c | 16 ++-------------- drivers/net/wireless/quantenna/qtnfmac/qlink_util.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/qtn_hw_ids.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/shm_ipc.c | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/shm_ipc.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/shm_ipc_defs.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/trans.c | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/trans.h | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/util.c | 17 ++--------------- drivers/net/wireless/quantenna/qtnfmac/util.h | 17 ++--------------- 23 files changed, 45 insertions(+), 327 deletions(-) diff --git a/drivers/net/wireless/quantenna/Makefile b/drivers/net/wireless/quantenna/Makefile index baebfbde119e..cea83d178d2e 100644 --- a/drivers/net/wireless/quantenna/Makefile +++ b/drivers/net/wireless/quantenna/Makefile @@ -1,3 +1,4 @@ +# SPDX-License-Identifier: GPL-2.0 # # Copyright (c) 2015-2016 Quantenna Communications, Inc. # All rights reserved. diff --git a/drivers/net/wireless/quantenna/qtnfmac/bus.h b/drivers/net/wireless/quantenna/qtnfmac/bus.h index 528ca7f5e070..7bd906cc7023 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/bus.h +++ b/drivers/net/wireless/quantenna/qtnfmac/bus.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015 Quantenna Communications - * - * Permission to use, copy, modify, and/or distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES - * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY - * SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES - * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION - * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN - * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015 Quantenna Communications. All rights reserved. */ #ifndef QTNFMAC_BUS_H #define QTNFMAC_BUS_H diff --git a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c index 1b02096934f8..45f4cef7de9c 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c +++ b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.c @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2012-2012 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include #include diff --git a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.h b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.h index b73425122a10..c374857283ac 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/cfg80211.h +++ b/drivers/net/wireless/quantenna/qtnfmac/cfg80211.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_CFG80211_H_ #define _QTN_FMAC_CFG80211_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.c b/drivers/net/wireless/quantenna/qtnfmac/commands.c index 3f0a0b6abf01..009a4e4f4c7a 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.c +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.c @@ -1,17 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include #include diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.h b/drivers/net/wireless/quantenna/qtnfmac/commands.h index 1c25e7905e9a..96dff643bbc4 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.h +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.h @@ -1,17 +1,5 @@ -/* - * Copyright (c) 2016 Quantenna Communications, Inc. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2016 Quantenna Communications. All rights reserved. */ #ifndef QLINK_COMMANDS_H_ #define QLINK_COMMANDS_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/core.c b/drivers/net/wireless/quantenna/qtnfmac/core.c index 29258acfa8dc..ee1b75fda1dd 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/core.c +++ b/drivers/net/wireless/quantenna/qtnfmac/core.c @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include #include diff --git a/drivers/net/wireless/quantenna/qtnfmac/core.h b/drivers/net/wireless/quantenna/qtnfmac/core.h index 293055049caa..a31cff46e964 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/core.h +++ b/drivers/net/wireless/quantenna/qtnfmac/core.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_CORE_H_ #define _QTN_FMAC_CORE_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/debug.c b/drivers/net/wireless/quantenna/qtnfmac/debug.c index 9f826b9ef5d9..ad70cdb80060 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/debug.c +++ b/drivers/net/wireless/quantenna/qtnfmac/debug.c @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include "debug.h" diff --git a/drivers/net/wireless/quantenna/qtnfmac/debug.h b/drivers/net/wireless/quantenna/qtnfmac/debug.h index d6dd12b5d434..61b45536b83a 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/debug.h +++ b/drivers/net/wireless/quantenna/qtnfmac/debug.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_DEBUG_H_ #define _QTN_FMAC_DEBUG_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/event.c b/drivers/net/wireless/quantenna/qtnfmac/event.c index 8b542b431b75..3038a000c287 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/event.c +++ b/drivers/net/wireless/quantenna/qtnfmac/event.c @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include #include diff --git a/drivers/net/wireless/quantenna/qtnfmac/event.h b/drivers/net/wireless/quantenna/qtnfmac/event.h index ae759b602c2a..533ad99d045d 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/event.h +++ b/drivers/net/wireless/quantenna/qtnfmac/event.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_EVENT_H_ #define _QTN_FMAC_EVENT_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink.h b/drivers/net/wireless/quantenna/qtnfmac/qlink.h index ace52e9d421d..d958b268de02 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_QLINK_H_ #define _QTN_QLINK_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink_util.c b/drivers/net/wireless/quantenna/qtnfmac/qlink_util.c index aeeda81b09ea..72bfd17cb687 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink_util.c +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink_util.c @@ -1,17 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h b/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h index fc87827cb49c..781ea7fe79f2 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink_util.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_QLINK_UTIL_H_ #define _QTN_FMAC_QLINK_UTIL_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/qtn_hw_ids.h b/drivers/net/wireless/quantenna/qtnfmac/qtn_hw_ids.h index 40295a511224..82d879950b62 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qtn_hw_ids.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qtn_hw_ids.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_HW_IDS_H_ #define _QTN_HW_IDS_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.c b/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.c index 2ec334199c2b..ff678951d3b2 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.c +++ b/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.c @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include #include diff --git a/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.h b/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.h index c2a3702a9ee7..52cac5439b03 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.h +++ b/drivers/net/wireless/quantenna/qtnfmac/shm_ipc.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_SHM_IPC_H_ #define _QTN_FMAC_SHM_IPC_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/shm_ipc_defs.h b/drivers/net/wireless/quantenna/qtnfmac/shm_ipc_defs.h index 95a5f89a8b1a..78be70df1218 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/shm_ipc_defs.h +++ b/drivers/net/wireless/quantenna/qtnfmac/shm_ipc_defs.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_SHM_IPC_DEFS_H_ #define _QTN_FMAC_SHM_IPC_DEFS_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/trans.c b/drivers/net/wireless/quantenna/qtnfmac/trans.c index 345f34ec9750..95356e280e23 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/trans.c +++ b/drivers/net/wireless/quantenna/qtnfmac/trans.c @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include #include diff --git a/drivers/net/wireless/quantenna/qtnfmac/trans.h b/drivers/net/wireless/quantenna/qtnfmac/trans.h index 9a473e07af0f..c0b76f871b31 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/trans.h +++ b/drivers/net/wireless/quantenna/qtnfmac/trans.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #ifndef _QTN_FMAC_TRANS_H_ #define _QTN_FMAC_TRANS_H_ diff --git a/drivers/net/wireless/quantenna/qtnfmac/util.c b/drivers/net/wireless/quantenna/qtnfmac/util.c index 3bc96b264769..cda6f5f3f38a 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/util.c +++ b/drivers/net/wireless/quantenna/qtnfmac/util.c @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015-2016 Quantenna Communications, Inc. - * All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - */ +// SPDX-License-Identifier: GPL-2.0+ +/* Copyright (c) 2015-2016 Quantenna Communications. All rights reserved. */ #include "util.h" #include "qtn_hw_ids.h" diff --git a/drivers/net/wireless/quantenna/qtnfmac/util.h b/drivers/net/wireless/quantenna/qtnfmac/util.h index b8744baac332..a14b7078a9c7 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/util.h +++ b/drivers/net/wireless/quantenna/qtnfmac/util.h @@ -1,18 +1,5 @@ -/* - * Copyright (c) 2015 Quantenna Communications - * - * Permission to use, copy, modify, and/or distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES - * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY - * SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES - * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION - * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN - * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* Copyright (c) 2015 Quantenna Communications. All rights reserved. */ #ifndef QTNFMAC_UTIL_H #define QTNFMAC_UTIL_H From patchwork Mon Jan 14 09:39:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761797 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-2.web.codeaurora.org (Postfix) with ESMTP id 9857C6C2 for ; Mon, 14 Jan 2019 09:41:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8A14628A94 for ; Mon, 14 Jan 2019 09:41:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7E94628ACE; Mon, 14 Jan 2019 09:41:14 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 E139728AB3 for ; Mon, 14 Jan 2019 09:41:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726587AbfANJlN (ORCPT ); Mon, 14 Jan 2019 04:41:13 -0500 Received: from mail-eopbgr810055.outbound.protection.outlook.com ([40.107.81.55]:63923 "EHLO NAM01-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726534AbfANJlN (ORCPT ); Mon, 14 Jan 2019 04:41:13 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ymfHPKhfkLQnWXEmJ88Gdnm5lSqSTVa3HVbGyJuuJfo=; b=qSShFGjkmBl/lZJRp7gkL41Zs1IJlRb54hqsVVIqS8sdP/mhBoCrabtAWl/gnfzhAtZJ6gH/ZOiTlG6U+aecczCREkXM2pTIY8EISAxq7yy/O9yBSAKO4Y6QNTSvAaj3npjje0EtsgGJk3klB+An/dg84LjTIuaPAxTA0iKCMzU= Received: from BL0PR05MB4818.namprd05.prod.outlook.com (52.132.15.24) by BL0PR05MB5665.namprd05.prod.outlook.com (10.167.240.202) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.10; Mon, 14 Jan 2019 09:41:00 +0000 Received: from BL0PR05MB4818.namprd05.prod.outlook.com ([fe80::147c:e119:a8da:4046]) by BL0PR05MB4818.namprd05.prod.outlook.com ([fe80::147c:e119:a8da:4046%2]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:41:00 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB4719.namprd05.prod.outlook.com (52.135.114.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:47 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:47 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 7/9] qtnfmac: add missing bss record to host scan cache Thread-Topic: [PATCH v2 7/9] qtnfmac: add missing bss record to host scan cache Thread-Index: AQHUq+0WYjocHjPXg0e7QZCT6+876g== Date: Mon, 14 Jan 2019 09:39:47 +0000 Message-ID: <20190114093925.9061-8-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BL0PR05MB5665;6:HAwhnHKGlNWQmzf64a3FLNSuBruuvYVSZBzIHonZ6FEczWAwo7bmT1ASwSZsULtobJjpB00yk95kBYkYfXAC36lZngqJ0geipvW0J3XjmS+q+8XfYGPiWCGqm5SmC7/282BIOvaRjJR44e4Z06A26yLWVJ1EBn+8dj5Mcu7DBF+FCFCO6auoIeIr/R+UON8sFFO1T2AVl9X+7b+bOGFWRxwGoD6elZXvFQEw/YEEhD/VBh3NaQAWvonoX0cTqWPE2a5y4ekmIlhoUJ4fQQOIlxoZB0iAqxpEXvXWCo5iYCkFw3WeEVWYI+zj3f02oB1EsCDVwfu7plsxGEaQLKoU832PxjOt8stQZKAM9iQ7wpnduVYkvyeF9Kh3N1d4kjA46pWeX/b+le+NurLYPYlFQaDXEpS3gtRkeDG5Ia7C2h27t9oZkPBoe7BPLlAb1mGxLa8jJuKfXnWDD/fyqhpSQA==;5:stW5++sOdAV45HM4D89uLVHzDH3kTz3M/6aKKQ10nMSxYv8FGXxBAWagcfsdFxcTZN4vIlPDJjPAydIcrnYlbQ7pffjpJ9NVHSglQDe7olX5j4ogRAe6jXZMhzrMMkFhD61rFO1/3b/74kbW9LmG1ZqzPLp4rQSG0IduXYib903L3ckPbkHDpeZ1QWqIeMSP8QKKIxRkpiAfslNpxWC7bA==;7:2leMLZBS9rjZRGWNwr3HaOjs+WzLjLWiVd8du94WB9EavZjTiTLxejGFzKHz0M6G5cdiSrzxsEu9Eu4co/nyaGplEAOPGF8qUYVsUJgIZ06EQLl44TCq3I8b3h7loZwuEP60TT/n7bkABlycMlik2g== x-ms-office365-filtering-correlation-id: 2cd05929-5dae-4cd9-ce93-08d67a0438b4 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(5600109)(711020)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB4719; x-ms-traffictypediagnostic: SN6PR05MB4719:|BL0PR05MB5665: authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-moderation-data: 1/14/2019 9:40:57 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(136003)(376002)(346002)(39840400004)(396003)(366004)(189003)(199004)(5640700003)(6916009)(2906002)(3846002)(386003)(26005)(99286004)(36756003)(14444005)(52116002)(2501003)(76176011)(186003)(71190400001)(6116002)(5660300001)(486006)(102836004)(71200400001)(446003)(436003)(256004)(2616005)(53936002)(6506007)(11346002)(1076003)(476003)(316002)(106356001)(14454004)(6512007)(4326008)(81166006)(66066001)(8676002)(81156014)(8936002)(103116003)(107886003)(25786009)(105586002)(305945005)(68736007)(7736002)(2351001)(6436002)(86362001)(575784001)(54906003)(478600001)(6486002)(97736004);DIR:OUT;SFP:1101;SCL:1;SRVR:BL0PR05MB5665;H:BL0PR05MB4818.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: QY4aM2TpctdzgdMuwveSGNehKKckbCJzsL5zCxNr97WdSUl6WTPKc4Ftsha/wFzHO13hdd+HvCCSFxDl4v+Y/AbptXMCy9/5X7H1nfaJs7EUDp4AuhenvKc26Rl4Vbcnf/o+LxsvFpJ8Nv88cGt9JThvzyfrCl6tHNrepQEx5DUB4rebEP6YjvN7A3KPgVWutr5DS6OnQ2OnABft4E2/NsGPwxGQ4mI2tRX9KFHSA7yS/1SsSu2ds1cNYPhoVBb4yWkMhgCGQm3oQL9Qo4e1IgXvmRt9w9famciXAF2JkC3dMmu9Hj5Z6A4Mm0bNdi0ec/Fgxq7P0mXpbTRmKY4lGdtKE8xDsHHhyFGyz1kePNzd58HCWxL5/Tx8G1YQPxwD7x/eLfi/zfrrCrkSNpZRqwTDsywfjigUQ4AQZVl4jak= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2cd05929-5dae-4cd9-ce93-08d67a0438b4 X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:41:00.4618 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR05MB5665 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 Make sure that valid BSS entry exists in wireless core record even in the case of successful connect reported by firmware. Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/qtnfmac/event.c | 79 ++++++++++++++++++++++++-- drivers/net/wireless/quantenna/qtnfmac/qlink.h | 4 +- 2 files changed, 78 insertions(+), 5 deletions(-) diff --git a/drivers/net/wireless/quantenna/qtnfmac/event.c b/drivers/net/wireless/quantenna/qtnfmac/event.c index 3038a000c287..3fd1a9217737 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/event.c +++ b/drivers/net/wireless/quantenna/qtnfmac/event.c @@ -145,6 +145,12 @@ qtnf_event_handle_bss_join(struct qtnf_vif *vif, const struct qlink_event_bss_join *join_info, u16 len) { + struct wiphy *wiphy = priv_to_wiphy(vif->mac); + enum ieee80211_statuscode status = le16_to_cpu(join_info->status); + struct cfg80211_chan_def chandef; + struct cfg80211_bss *bss = NULL; + u8 *ie = NULL; + if (unlikely(len < sizeof(*join_info))) { pr_err("VIF%u.%u: payload is too short (%u < %zu)\n", vif->mac->macid, vif->vifid, len, @@ -158,15 +164,80 @@ qtnf_event_handle_bss_join(struct qtnf_vif *vif, return -EPROTO; } - pr_debug("VIF%u.%u: BSSID:%pM\n", vif->mac->macid, vif->vifid, - join_info->bssid); + pr_debug("VIF%u.%u: BSSID:%pM status:%u\n", + vif->mac->macid, vif->vifid, join_info->bssid, status); + + if (status == WLAN_STATUS_SUCCESS) { + qlink_chandef_q2cfg(wiphy, &join_info->chan, &chandef); + if (!cfg80211_chandef_valid(&chandef)) { + pr_warn("MAC%u.%u: bad channel freq=%u cf1=%u cf2=%u bw=%u\n", + vif->mac->macid, vif->vifid, + chandef.chan->center_freq, + chandef.center_freq1, + chandef.center_freq2, + chandef.width); + status = WLAN_STATUS_UNSPECIFIED_FAILURE; + goto done; + } + bss = cfg80211_get_bss(wiphy, chandef.chan, join_info->bssid, + NULL, 0, IEEE80211_BSS_TYPE_ESS, + IEEE80211_PRIVACY_ANY); + if (!bss) { + pr_warn("VIF%u.%u: add missing BSS:%pM chan:%u\n", + vif->mac->macid, vif->vifid, + join_info->bssid, chandef.chan->hw_value); + + if (!vif->wdev.ssid_len) { + pr_warn("VIF%u.%u: SSID unknown for BSS:%pM\n", + vif->mac->macid, vif->vifid, + join_info->bssid); + status = WLAN_STATUS_UNSPECIFIED_FAILURE; + goto done; + } + + ie = kzalloc(2 + vif->wdev.ssid_len, GFP_KERNEL); + if (!ie) { + pr_warn("VIF%u.%u: IE alloc failed for BSS:%pM\n", + vif->mac->macid, vif->vifid, + join_info->bssid); + status = WLAN_STATUS_UNSPECIFIED_FAILURE; + goto done; + } + + ie[0] = WLAN_EID_SSID; + ie[1] = vif->wdev.ssid_len; + memcpy(ie + 2, vif->wdev.ssid, vif->wdev.ssid_len); + + bss = cfg80211_inform_bss(wiphy, chandef.chan, + CFG80211_BSS_FTYPE_UNKNOWN, + join_info->bssid, 0, + WLAN_CAPABILITY_ESS, 100, + ie, 2 + vif->wdev.ssid_len, + 0, GFP_KERNEL); + if (!bss) { + pr_warn("VIF%u.%u: can't connect to unknown BSS: %pM\n", + vif->mac->macid, vif->vifid, + join_info->bssid); + status = WLAN_STATUS_UNSPECIFIED_FAILURE; + goto done; + } + } + } + +done: cfg80211_connect_result(vif->netdev, join_info->bssid, NULL, 0, NULL, - 0, le16_to_cpu(join_info->status), GFP_KERNEL); + 0, status, GFP_KERNEL); + if (bss) { + if (!ether_addr_equal(vif->bssid, join_info->bssid)) + ether_addr_copy(vif->bssid, join_info->bssid); + cfg80211_put_bss(wiphy, bss); + } - if (le16_to_cpu(join_info->status) == WLAN_STATUS_SUCCESS) + if (status == WLAN_STATUS_SUCCESS) netif_carrier_on(vif->netdev); + kfree(ie); return 0; } diff --git a/drivers/net/wireless/quantenna/qtnfmac/qlink.h b/drivers/net/wireless/quantenna/qtnfmac/qlink.h index d958b268de02..27fdb5b01ee3 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/qlink.h +++ b/drivers/net/wireless/quantenna/qtnfmac/qlink.h @@ -6,7 +6,7 @@ #include -#define QLINK_PROTO_VER 12 +#define QLINK_PROTO_VER 13 #define QLINK_MACID_RSVD 0xFF #define QLINK_VIFID_RSVD 0xFF @@ -975,11 +975,13 @@ struct qlink_event_sta_deauth { /** * struct qlink_event_bss_join - data for QLINK_EVENT_BSS_JOIN event * + * @chan: new operating channel definition * @bssid: BSSID of a BSS which interface tried to joined. * @status: status of joining attempt, see &enum ieee80211_statuscode. */ struct qlink_event_bss_join { struct qlink_event ehdr; + struct qlink_chandef chan; u8 bssid[ETH_ALEN]; __le16 status; } __packed; From patchwork Mon Jan 14 09:39:49 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761793 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-2.web.codeaurora.org (Postfix) with ESMTP id 7686813B5 for ; Mon, 14 Jan 2019 09:41:04 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6A09028A78 for ; Mon, 14 Jan 2019 09:41:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 68AA928AF3; Mon, 14 Jan 2019 09:41:04 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 C365A28AC6 for ; Mon, 14 Jan 2019 09:41:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726572AbfANJlC (ORCPT ); Mon, 14 Jan 2019 04:41:02 -0500 Received: from mail-eopbgr710076.outbound.protection.outlook.com ([40.107.71.76]:23296 "EHLO NAM05-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726534AbfANJlC (ORCPT ); Mon, 14 Jan 2019 04:41:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lQQ7qDSZU79SgWvL7ySSsgjcHu98628R4hDFE5kyiMQ=; b=TGeNlA+7LbiO0jJrP6s37Hlrpx4yqHp2VQ5RyRFJZxU5Ym2nh01N6QI9aKpdo7voFjJ8njS3N8OyhPU18f38gaJOXBAhHErCNUlYefBvZGpvbLu9E7NJoOx+WdB6MYs5H2S4xb+D5UBWOHifeFjnZF0cBdWvq7gOF49HDQTUQi0= Received: from CY4PR0501MB3873.namprd05.prod.outlook.com (52.132.100.150) by CY4PR0501MB3827.namprd05.prod.outlook.com (52.132.100.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.18; Mon, 14 Jan 2019 09:40:52 +0000 Received: from CY4PR0501MB3873.namprd05.prod.outlook.com ([fe80::f9eb:3f89:1cf3:30f8]) by CY4PR0501MB3873.namprd05.prod.outlook.com ([fe80::f9eb:3f89:1cf3:30f8%4]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:40:52 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB4719.namprd05.prod.outlook.com (52.135.114.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:49 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:49 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 8/9] qtnfmac: remove unused declarations Thread-Topic: [PATCH v2 8/9] qtnfmac: remove unused declarations Thread-Index: AQHUq+0XcvOinKzFYUajo/r7qJSRew== Date: Mon, 14 Jan 2019 09:39:49 +0000 Message-ID: <20190114093925.9061-9-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;CY4PR0501MB3827;6:uRV6mRKcHXVwuN2bvpUmDGepVlxFGxSc2mLrriGj8znocqnFJaZOJvW/CUxa+BFJS3B8AdJPZfgYQw2kX+koAQmA7DYLbuwRUZ/UZIQDxJe+MQplCrstdjc0Y/07fs5y+UV6HjjcoF+evu/3OsMAxBUbO8OkKbp8I/MT7zMNXGc9UBk9TyYKkn7qPZNpuVyFoS7M0iVXLMX5TL5KdiT+FhMkATrxCMx5npNAYUI867nbbuBJBX+oANsUNlS1xgm1329KK7i7375v62zb3hVKm9397eAMXS9WpFbOxrhR4LwOjJj7Ww76Hea85TkfmxzwgKb8QcGn77gX2K5SQJrknshafod/yYOqDmXFsHBNO4UVnhr1TBfjgKJkJQW7wsd6uNvGYmsC2bmkMd9eOeiXMaiEC7SUzpoWEWsSaOF8SHdj7xCfahtmRPyCHv37nBEO911Krgb2OK/aUh0kJQ/eUw==;5:jxHDX5cT2vPsJVX2cJ++ory2xwuEEaPNOfdU6gXLhuyVhdMSJKpLOfJayF3/+kAAhTF9YoBSWAoKlr6+pN6fHzyDNMlBCP5+vmvHqGuUIb0zp8Jx5745lRD12WtpMCIh4hvSvKRXDSQ2diXETnhSefTe4RHR8lj5wPQFABdWE6hJfQETeZGZS+DkJFPH54D7fqAkZc1NjwMYZkL1AnVIrw==;7:JpoiaN5CvlfOHGoadL21nnntGI9xDRltT3W4wbsMto7P+CPLE9lLFliTX5QOtBlxlKBPM4KxvTSiP7TXB3a9XUFb6pktAv49qegv4fUC2lrloLBxcDuiv6gSe3m2ojb3Ne2+8p1Fg+3t+JXaglSlXA== x-ms-office365-filtering-correlation-id: 6eebdff8-c3cb-4268-bb90-08d67a0439dc x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(5600109)(711020)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB4719; x-ms-traffictypediagnostic: SN6PR05MB4719:|CY4PR0501MB3827: authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-moderation-data: 1/14/2019 9:40:50 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(136003)(396003)(346002)(376002)(366004)(39840400004)(189003)(199004)(2616005)(103116003)(86362001)(478600001)(476003)(5640700003)(6916009)(316002)(54906003)(6486002)(6436002)(436003)(97736004)(2501003)(14454004)(25786009)(3846002)(6116002)(386003)(66066001)(6506007)(486006)(7736002)(102836004)(52116002)(446003)(76176011)(11346002)(4326008)(26005)(305945005)(36756003)(186003)(8676002)(81156014)(81166006)(8936002)(5024004)(68736007)(2351001)(107886003)(6512007)(53936002)(1076003)(5660300001)(2906002)(99286004)(71200400001)(71190400001)(106356001)(256004)(105586002);DIR:OUT;SFP:1101;SCL:1;SRVR:CY4PR0501MB3827;H:CY4PR0501MB3873.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: QsqQc8z0QyFKu3EkIdDRuQ8WELVl4DODssjTrMocYWNaFKpOl97sijZdm5v4l7bjVM7etsYi6HtNvjyjAamJlPGiaeqhRIpvoW1m+RC/M/n1i+kZvLnUWw1FFrWK4Gb9QcjMJCjL1kII7CFd2F9ei8GW4yhomFNlUQQR2WzJVC3pojOW+IEpgHqOy6VP2BRPqTl4TSMwqnT6wFH6xDSFtXmYS3EvJQyrTtCMBdzS6GVgmGJ6yGIn5oWflZUeWgC8nZV0JKHaZGbsirSRG846bSh83b+xLo8/3VvnNexkViZn2sxDdpotpmtZw3gYc8hPUpLB86BWMxldaKSJaU4mvol5awpu7MlBY36FsSFrzjhHrJI16Lc2wEkhOFHzguu+wREUqlJ5tXfCgs34qWYBAxTxSn2SmHVp0knAaqSBzdo= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6eebdff8-c3cb-4268-bb90-08d67a0439dc X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:52.5182 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR0501MB3827 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 Remove declarations for inexistent functions from bus.h header. Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/qtnfmac/bus.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/net/wireless/quantenna/qtnfmac/bus.h b/drivers/net/wireless/quantenna/qtnfmac/bus.h index 7bd906cc7023..14b569b6d1b5 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/bus.h +++ b/drivers/net/wireless/quantenna/qtnfmac/bus.h @@ -122,7 +122,5 @@ static __always_inline void qtnf_bus_unlock(struct qtnf_bus *bus) int qtnf_core_attach(struct qtnf_bus *bus); void qtnf_core_detach(struct qtnf_bus *bus); -void qtnf_txflowblock(struct device *dev, bool state); -void qtnf_txcomplete(struct device *dev, struct sk_buff *txp, bool success); #endif /* QTNFMAC_BUS_H */ From patchwork Mon Jan 14 09:39:51 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Matyukevich X-Patchwork-Id: 10761795 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-2.web.codeaurora.org (Postfix) with ESMTP id 168FC6C2 for ; Mon, 14 Jan 2019 09:41:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 09A7728AF7 for ; Mon, 14 Jan 2019 09:41:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0819728AF9; Mon, 14 Jan 2019 09:41:07 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,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 A624E28B04 for ; Mon, 14 Jan 2019 09:41:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726581AbfANJlF (ORCPT ); Mon, 14 Jan 2019 04:41:05 -0500 Received: from mail-eopbgr740078.outbound.protection.outlook.com ([40.107.74.78]:8356 "EHLO NAM01-BN3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726534AbfANJlF (ORCPT ); Mon, 14 Jan 2019 04:41:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quantenna.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+Z/BHPRHajLJg2l1af9elfwbb3SczJ+QaKw9N+cDIys=; b=JbPgd56QWizUVA6y2rixzWUOrLyW7Ovvrq3l/SZH9j9zxdJ+iPHpwjlHia81WVdcr4YG1hFgadyeR59pfRDB/4GdFa81a2wmSqvvqZIsVYQjoZMIcs3R6TjqK6oQjSDT8c/4LD7p0+VG3yduMafugoNNjlIFXIAfsv2gOdzfEHM= Received: from BN6PR05MB3282.namprd05.prod.outlook.com (10.174.95.29) by BN6PR05MB3316.namprd05.prod.outlook.com (10.174.95.138) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.18; Mon, 14 Jan 2019 09:40:56 +0000 Received: from BN6PR05MB3282.namprd05.prod.outlook.com ([fe80::ccd1:be31:d057:fab1]) by BN6PR05MB3282.namprd05.prod.outlook.com ([fe80::ccd1:be31:d057:fab1%4]) with mapi id 15.20.1537.017; Mon, 14 Jan 2019 09:40:56 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com (52.135.117.74) by SN6PR05MB4719.namprd05.prod.outlook.com (52.135.114.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.17; Mon, 14 Jan 2019 09:39:51 +0000 Received: from SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5]) by SN6PR05MB4928.namprd05.prod.outlook.com ([fe80::6d1c:886b:bd14:71c5%6]) with mapi id 15.20.1537.018; Mon, 14 Jan 2019 09:39:51 +0000 From: Sergey Matyukevich To: "linux-wireless@vger.kernel.org" CC: Igor Mitsyanko , Andrey Shevchenko , Sergey Matyukevich Subject: [PATCH v2 9/9] qtnfmac: qtnf_cmd_send_with_reply cleanup Thread-Topic: [PATCH v2 9/9] qtnfmac: qtnf_cmd_send_with_reply cleanup Thread-Index: AQHUq+0YA6CFUVawY0+2uKx2Ytq5QA== Date: Mon, 14 Jan 2019 09:39:51 +0000 Message-ID: <20190114093925.9061-10-sergey.matyukevich.os@quantenna.com> References: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> In-Reply-To: <20190114093925.9061-1-sergey.matyukevich.os@quantenna.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR05CA0070.namprd05.prod.outlook.com (2603:10b6:a03:74::47) To SN6PR05MB4928.namprd05.prod.outlook.com (2603:10b6:805:9d::10) x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [195.182.157.78] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BN6PR05MB3316;6:hFSyzt8A/WM1PDIVIaIOF/NVmDs1PjDNkiZVkQPAWqM3uHmWIHC4JAVYQ5EBBKs/l2i2k2S8PtiB8KCofkpaym26BJZq2ZFlHwcQfuHIhedIGwv2KIZwQpmFW3gpvIklyKaMaurxEJelF61fF8rnBUaY7wIOx2ZU74UQBuEw15rOzGk0LJr3Uwrf3jVN0FANnMP1jvSTj/Yf9hxulCioPa9VJdaLJZfxDLDuqWZILcPSd9zPKw9cVnFWUdPO95y530s48iXh4Y1lvUokTlZv3cigGHkXxom1H9p+VcoyqF5XXbIyba2ZxukZh/kX1hoaeg6NRsO177TAatozI61TWC777Y2xoKA2kNT57eBa40g7WmbywWNPWyhF79PzB3OuIS3nBoEiJ743ops/GNaHYOptY4WAZG4f/zQoTZ1Yp5hSsFzCdpKMGbl8F1hV22AL3w5yrk5MpiAcNhAsJV3lpQ==;5:GwAzWOThswhhERn6y8h6bG3RdvEWJDc3eOoI6hH3era3di9QcFA3rVrwnlSBUQBTq1QMhlMlsNU5XJlubcWxwgM8wYE31XmCpKcsWjw8rnDhKvqnqZaai3BR2RS8Szlop2UcYpx3y7WoJnglr7R9qhtkOC7FySD1ZX3H+O7tUHAuaYNvysJoRJUIMHdfwrMA/jfd1LF6vwTv4kpU3JCB6A==;7:GX43BdvHJnYhurmBxFQRlA0lSd06406YdJgFuLtigLhUv8VmivvEtojRV0qUeqTCX1qu2pI76Zwz1tTRCF8D3Ut/qao1MkMBtRhF2NHf4xT8Fc6V3K3sD3xzCkV0mOJ07VnlIi1j5fGrsjRaYfRCjg== x-ms-office365-filtering-correlation-id: eaf39c68-b61c-4347-1b84-08d67a043afc x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(5600109)(711020)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020);SRVR:SN6PR05MB4719; x-ms-traffictypediagnostic: SN6PR05MB4719:|BN6PR05MB3316: authentication-results: spf=none (sender IP is ) smtp.mailfrom=sergey.matyukevich.os@quantenna.com; x-moderation-data: 1/14/2019 9:40:52 AM x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(346002)(366004)(396003)(136003)(39840400004)(376002)(199004)(189003)(54906003)(446003)(476003)(103116003)(436003)(106356001)(99286004)(478600001)(105586002)(186003)(1076003)(2616005)(11346002)(6512007)(2351001)(486006)(68736007)(4326008)(316002)(107886003)(53936002)(66066001)(386003)(6506007)(102836004)(2501003)(25786009)(14454004)(26005)(71190400001)(76176011)(71200400001)(3846002)(52116002)(6116002)(81156014)(7736002)(81166006)(6916009)(2906002)(8676002)(5660300001)(36756003)(5640700003)(97736004)(86362001)(8936002)(575784001)(6486002)(305945005)(256004)(6436002);DIR:OUT;SFP:1101;SCL:1;SRVR:BN6PR05MB3316;H:BN6PR05MB3282.namprd05.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: quantenna.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: QyyBMay0lso0pIwNC+a0rwLZ1JQdYjCQPWBAveD44Uk6U9Q/7QxFUjaqq2+Y9okqWugjMK0u75FCFkGGxk4sIIFn6z+cQebXEmmCa/auHUb8X6L+TD7TQUxOCYEQEosAlEiStuzqIOslMaxmn/Dq0ntyeyyNmlULh6A7ay7tj0SSFXZjgQOApexvPfh4oB3X18p7GPErEYck9jmrLVjqkk7Vvg6CnwhLt89l9ZgutXk33OUUlYYYFGgMjE343xTwVRvjBGOnb2rFbhg5Irsz2COwGpuquO5Kk1xD3EZCxwECoHw1NJ6FKREavwEYOFy2YotSHGgHz873g+hhsPlyB2wfOLcc1axTLndSQ7opnhUA5qbDKkV4xHZioQO3bjbqiOrFxjD5kaRV6YrnVkGyP+v3dhoA+W+Lc4lxfRUEW38= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-Network-Message-Id: eaf39c68-b61c-4347-1b84-08d67a043afc X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a355dbce-62b4-4789-9446-c1d5582180ff X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 09:40:56.0545 (UTC) X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR05MB3316 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 Use existing variable with dereferenced cmd_id field. Signed-off-by: Sergey Matyukevich --- drivers/net/wireless/quantenna/qtnfmac/commands.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/net/wireless/quantenna/qtnfmac/commands.c b/drivers/net/wireless/quantenna/qtnfmac/commands.c index 009a4e4f4c7a..9b3019b0f108 100644 --- a/drivers/net/wireless/quantenna/qtnfmac/commands.c +++ b/drivers/net/wireless/quantenna/qtnfmac/commands.c @@ -87,14 +87,12 @@ static int qtnf_cmd_send_with_reply(struct qtnf_bus *bus, vif_id = cmd->vifid; cmd->mhdr.len = cpu_to_le16(cmd_skb->len); - pr_debug("VIF%u.%u cmd=0x%.4X\n", mac_id, vif_id, - le16_to_cpu(cmd->cmd_id)); + pr_debug("VIF%u.%u cmd=0x%.4X\n", mac_id, vif_id, cmd_id); if (bus->fw_state != QTNF_FW_STATE_ACTIVE && - le16_to_cpu(cmd->cmd_id) != QLINK_CMD_FW_INIT) { + cmd_id != QLINK_CMD_FW_INIT) { pr_warn("VIF%u.%u: drop cmd 0x%.4X in fw state %d\n", - mac_id, vif_id, le16_to_cpu(cmd->cmd_id), - bus->fw_state); + mac_id, vif_id, cmd_id, bus->fw_state); dev_kfree_skb(cmd_skb); return -ENODEV; } @@ -128,7 +126,7 @@ static int qtnf_cmd_send_with_reply(struct qtnf_bus *bus, return qtnf_cmd_resp_result_decode(le16_to_cpu(resp->result)); pr_warn("VIF%u.%u: cmd 0x%.4X failed: %d\n", - mac_id, vif_id, le16_to_cpu(cmd->cmd_id), ret); + mac_id, vif_id, cmd_id, ret); return ret; }