Message ID | 20200115121041.10863-41-Jerome.Pouiller@silabs.com (mailing list archive) |
---|---|
State | Not Applicable |
Delegated to: | Johannes Berg |
Headers | show
Return-Path: <SRS0=LItA=3E=vger.kernel.org=linux-wireless-owner@kernel.org> Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 18C46138D for <patchwork-linux-wireless@patchwork.kernel.org>; Wed, 15 Jan 2020 12:17:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E1A3822522 for <patchwork-linux-wireless@patchwork.kernel.org>; Wed, 15 Jan 2020 12:17:00 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=silabs.onmicrosoft.com header.i=@silabs.onmicrosoft.com header.b="hWoeHkwd" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731652AbgAOMQz (ORCPT <rfc822;patchwork-linux-wireless@patchwork.kernel.org>); Wed, 15 Jan 2020 07:16:55 -0500 Received: from mail-bn7nam10on2085.outbound.protection.outlook.com ([40.107.92.85]:6101 "EHLO NAM10-BN7-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1731304AbgAOMNd (ORCPT <rfc822;linux-wireless@vger.kernel.org>); Wed, 15 Jan 2020 07:13:33 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PDyTyk9vLjtwuwpQx/+LwZr88OZM/k6SCZdAAbbwx1vYvMgV2bg2XupcmTO+83Zaef+qMDISNheviOkYwV+YFY67/oMcdBcl8kJffSeJ1uZ2NlfLrSrkymEc6wbVXYqEwtLhJDBt/z6zSwWPfqXUFZ1euf8ie6pay31nPx3sEFKD6SPJZK7PLHI21zkVSw/zecL20yOchU9ojoPiiskYGUCx0i5JgRHkjpL+/+6rugkX+ZueCGe0Xj9nY2oYOLVwcyFeHpot4OZXHlJFtnlQVNgR+SspgJ1gWEovn6avwcbF0V0OHAWHakv2qrH11vzIkDPn7/g04RrgbAmOTmah2g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=dyYeovap0+RlWylFVGyolLwgpnfFNImokIBu+J3RC7k=; b=Bk/B59DBpUor6oocZpujrWBw2YWavj2rDBAs6aU62pcs3ceNQotl0Y6Y5W6ExATF4XIv9AxrnQQE909vLUB4/Tk6C+AuYQW5rP5n0OFzGLqWIr49A6y1dt9qHbzYo0xpcHyS1OOy9Ud4JHTb+KFeTxEafOsunImejx2AuoxByhDYPfTv48fg2Zt8IteEBMXfNNnvGCwZAcG51X7VqWtUdYP+jMoP9uBhgzL/LixxmiTlDCDnwkqlvUSYfEiuIbH63qZd8AYOxKNZ2j5RNIwN+GruIQuINeMcCgHWOyBnb5LHwvGKVisRobGLmguHfar7AgKzkuZTWLATem2rWtZtmw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=silabs.com; dmarc=pass action=none header.from=silabs.com; dkim=pass header.d=silabs.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=silabs.onmicrosoft.com; s=selector2-silabs-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=dyYeovap0+RlWylFVGyolLwgpnfFNImokIBu+J3RC7k=; b=hWoeHkwdYAw84Bw+5zlJoIvxUJXLdR4q9ljd6fGwNb5zLfjnTP+EFTgT24f5whhAcFX/rCEA5MPGh1NtssAZNKYWIyBbFuuJ3hoCmuY58A5N5+Zfqsp0bYKiX1JInmwqSkFwf4uJhMkuHQd7S4tP6itZUdaUcsXAMFUy+43CRWo= Received: from MN2PR11MB4063.namprd11.prod.outlook.com (10.255.180.22) by MN2PR11MB3934.namprd11.prod.outlook.com (10.255.180.212) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2644.20; Wed, 15 Jan 2020 12:13:26 +0000 Received: from MN2PR11MB4063.namprd11.prod.outlook.com ([fe80::f46c:e5b4:2a85:f0bf]) by MN2PR11MB4063.namprd11.prod.outlook.com ([fe80::f46c:e5b4:2a85:f0bf%4]) with mapi id 15.20.2623.018; Wed, 15 Jan 2020 12:13:26 +0000 Received: from pc-42.silabs.com (37.71.187.125) by PR2PR09CA0009.eurprd09.prod.outlook.com (2603:10a6:101:16::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2644.18 via Frontend Transport; Wed, 15 Jan 2020 12:13:01 +0000 From: =?utf-8?b?SsOpcsO0bWUgUG91aWxsZXI=?= <Jerome.Pouiller@silabs.com> To: "devel@driverdev.osuosl.org" <devel@driverdev.osuosl.org>, "linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org> CC: "netdev@vger.kernel.org" <netdev@vger.kernel.org>, "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Kalle Valo <kvalo@codeaurora.org>, "David S . Miller" <davem@davemloft.net>, =?utf-8?b?SsOpcsO0bWUgUG91aWxsZXI=?= <Jerome.Pouiller@silabs.com> Subject: [PATCH 40/65] staging: wfx: update power-save per interface Thread-Topic: [PATCH 40/65] staging: wfx: update power-save per interface Thread-Index: AQHVy50i9glpmyHt302vrCTD6a5IRw== Date: Wed, 15 Jan 2020 12:13:02 +0000 Message-ID: <20200115121041.10863-41-Jerome.Pouiller@silabs.com> References: <20200115121041.10863-1-Jerome.Pouiller@silabs.com> In-Reply-To: <20200115121041.10863-1-Jerome.Pouiller@silabs.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: PR2PR09CA0009.eurprd09.prod.outlook.com (2603:10a6:101:16::21) To MN2PR11MB4063.namprd11.prod.outlook.com (2603:10b6:208:13f::22) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Jerome.Pouiller@silabs.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.25.0 x-originating-ip: [37.71.187.125] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: efa3bf8a-eace-4c16-2ee7-08d799b444ab x-ms-traffictypediagnostic: MN2PR11MB3934: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: <MN2PR11MB39343ED30C2AC372D7B35D5193370@MN2PR11MB3934.namprd11.prod.outlook.com> x-ms-oob-tlc-oobclassifiers: OLM:7691; x-forefront-prvs: 02830F0362 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(396003)(136003)(39860400002)(376002)(366004)(346002)(199004)(189003)(54906003)(110136005)(86362001)(956004)(107886003)(2616005)(316002)(36756003)(71200400001)(52116002)(7696005)(478600001)(8936002)(81156014)(8676002)(4326008)(81166006)(6486002)(2906002)(26005)(66946007)(16526019)(186003)(5660300002)(66574012)(1076003)(66556008)(64756008)(66446008)(85182001)(66476007)(85202003)(60793003);DIR:OUT;SFP:1101;SCL:1;SRVR:MN2PR11MB3934;H:MN2PR11MB4063.namprd11.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: silabs.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: qdWwfoOnhVUL9FL1CxB2ekQ5KH+pCMHajdNIk287eptjvPegaqxlF2Z/oJu7QAXchj7XZBwqB/tGD5FSvhZfwaDS50tf9gs8c0Epvv2HEnnmeCM4SJSCJnUAimng5DTkv8nuHHI6LADRz2if4sTuGY46benDJKD9oUny8U8wkJCeRqCaoY0e5hHk6sr0lvVQVbDZW2Cpllcp6ZH9TL13ovptEeXRBNmSYicQYXAf0oqFagzQeIj1YTjpvIm800GqJ6+A3N2qsC5FePfaGR8B0iqRON/wABk3Lc3uoTcSNau10J9G1FjFaWEXdmjyukc80YWxPckOtHMROEBycIseD6KYsv840ulcoQMPBlrjsIqIU/KvYi68Tuz3TRY3df8QxReiMST+Oj0Kwhdpx7G4IWfVzxwsUfYGnFu0QrGxa8Q8YCC3zjib0C+MV7EEMluD4vwmVFDxXDwLPAxyvEG14pIAQJkyhqXb6WbHb9IAwYw= Content-Type: text/plain; charset="utf-8" Content-ID: <5C799CD8486500429F58F7BABF31182D@namprd11.prod.outlook.com> Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: silabs.com X-MS-Exchange-CrossTenant-Network-Message-Id: efa3bf8a-eace-4c16-2ee7-08d799b444ab X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Jan 2020 12:13:02.3215 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 54dbd822-5231-4b20-944d-6f4abcd541fb X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 6MqGMlVk8U4dvW/+2A2FRQuQz+3B1pP47Ew3oYMPoA/l07hytr64/xNo1wcHnN1V8Z3gauiT7zturvt15kmn0g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR11MB3934 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: <linux-wireless.vger.kernel.org> X-Mailing-List: linux-wireless@vger.kernel.org |
Series |
Simplify and improve the wfx driver
|
expand
|
diff --git a/drivers/staging/wfx/main.c b/drivers/staging/wfx/main.c index 1904890c03fe..84adad64fc30 100644 --- a/drivers/staging/wfx/main.c +++ b/drivers/staging/wfx/main.c @@ -131,7 +131,7 @@ static const struct ieee80211_ops wfx_ops = { .stop = wfx_stop, .add_interface = wfx_add_interface, .remove_interface = wfx_remove_interface, - .config = wfx_config, + .config = wfx_config, .tx = wfx_tx, .conf_tx = wfx_conf_tx, .hw_scan = wfx_hw_scan, diff --git a/drivers/staging/wfx/sta.c b/drivers/staging/wfx/sta.c index 0c3150a94c7c..94683a1440c8 100644 --- a/drivers/staging/wfx/sta.c +++ b/drivers/staging/wfx/sta.c @@ -826,6 +826,10 @@ void wfx_bss_info_changed(struct ieee80211_hw *hw, if (changed & BSS_CHANGED_TXPOWER) hif_set_output_power(wvif, info->txpower); + + if (changed & BSS_CHANGED_PS) + wfx_update_pm(wvif); + mutex_unlock(&wdev->conf_mutex); if (do_join) @@ -1058,18 +1062,7 @@ void wfx_unassign_vif_chanctx(struct ieee80211_hw *hw, int wfx_config(struct ieee80211_hw *hw, u32 changed) { - int ret = 0; - struct wfx_dev *wdev = hw->priv; - struct wfx_vif *wvif; - - if (changed & IEEE80211_CONF_CHANGE_PS) { - mutex_lock(&wdev->conf_mutex); - wvif = NULL; - while ((wvif = wvif_iterate(wdev, wvif)) != NULL) - ret = wfx_update_pm(wvif); - mutex_unlock(&wdev->conf_mutex); - } - return ret; + return 0; } int wfx_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif)