From patchwork Wed Jan 18 10:48:54 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 9523103 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0E211601B7 for ; Wed, 18 Jan 2017 10:49:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0CDCA285D1 for ; Wed, 18 Jan 2017 10:49:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 01B7F285D6; Wed, 18 Jan 2017 10:49:28 +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=-6.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM 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 830F6285D1 for ; Wed, 18 Jan 2017 10:49:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751946AbdARKt1 (ORCPT ); Wed, 18 Jan 2017 05:49:27 -0500 Received: from mail-lf0-f66.google.com ([209.85.215.66]:35788 "EHLO mail-lf0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751928AbdARKt0 (ORCPT ); Wed, 18 Jan 2017 05:49:26 -0500 Received: by mail-lf0-f66.google.com with SMTP id v186so1176817lfa.2 for ; Wed, 18 Jan 2017 02:49:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=BD+TMLRy7gbNhLMXzClsejSlXsZs+tX5k8nSvDViidE=; b=dvk6VZnNX2oD/+9rLGZwp1N4dHcI8yfY3z7j2IOLvuUy3isyY/j6dZRP1elhMuvuFk 53C2Ux5mWibpV8nuOtPVDMjLJvMqMdooPTgWpFtsF/HgnLW96rOZjhU4Y+heyVhw/09H lFHd6GFJaZIkUHCVrFk1FxjId6oDMVCu42nd7iW4Qf5ybyGScLhq8+J+o8E+0WzNas0p YBvOj5rx06cu770EnMZqdWgqw00Ifwlik5I2lQr5Nz+WvyS7P5eqPlVE1nbnga+4fShc KiDe4506aXO2EZT0qeavAeHXzklAHqOefnlPIY24BtjsvrTTWWFQWFDcASTAgo4DGTzT NF7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=BD+TMLRy7gbNhLMXzClsejSlXsZs+tX5k8nSvDViidE=; b=aa0qPOnDn+vT7ITJx9pCddN3Z0g6L5jAHSJ7XP79GUWFfQYMCaSCkT6F0uQikr7si+ 39wB6yYT9cCa0RHdqdHUTxdKV2AFmJxT9i4bBmIE+27mHPsUhDryDQjdJ9QtX39fwRp2 agWyuHnN9BEokA2Aug9Abjnr0u+/UCxapyF0VEmUQJPRgxUflSuf/0BoFklVuB23WtMq l+kYSpGFiEUY+HrcaWF+cVnz56b38qqdiydJ8HZNa/5sMCpbOL1O+T2XlcCEkiUEwY7N A9ogV0NHeNiZEQqDx1Xa/YDn1ep67U2lAWmR2JeisR78LjaODN3OJL2DyPPMbOVMzSip stNA== X-Gm-Message-State: AIkVDXIzmHRWQWE1gXyP8EU93miQA1g1lNtcRGH9eP/KTW3qb9qqPp0YfMVNhjFk5FQp4Q== X-Received: by 10.25.24.42 with SMTP id o42mr807735lfi.113.1484736564190; Wed, 18 Jan 2017 02:49:24 -0800 (PST) Received: from linux-samsung.lan (ip-194-187-74-233.konfederacka.maverick.com.pl. [194.187.74.233]) by smtp.gmail.com with ESMTPSA id d79sm10281578lfd.46.2017.01.18.02.49.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 18 Jan 2017 02:49:23 -0800 (PST) From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= To: Kalle Valo Cc: Arend van Spriel , Franky Lin , Hante Meuleman , Pieter-Paul Giesberts , Franky Lin , linux-wireless@vger.kernel.org, brcm80211-dev-list.pdl@broadcom.com, =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= Subject: [PATCH V2 4/4] brcmfmac: rename brcmf_bus_start function to brcmf_bus_started Date: Wed, 18 Jan 2017 11:48:54 +0100 Message-Id: <20170118104854.32231-4-zajec5@gmail.com> X-Mailer: git-send-email 2.10.1 In-Reply-To: <20170118104854.32231-1-zajec5@gmail.com> References: <20170118104854.32231-1-zajec5@gmail.com> MIME-Version: 1.0 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: Rafał Miłecki This intends to make init/attach process slightly easier to follow. What driver was doing in brcmf_bus_start wasn't bus specific at all and function brcmf_bus_stop wasn't undoing things done there. This function is supposed to be called by bus specific code when the bus is ready. Signed-off-by: Rafał Miłecki Acked-by: Arend van Spriel --- V2: Use "brcmf_bus_started" name instead of "brcmf_attach_phase2", don't rename brcmf_attach. --- drivers/net/wireless/broadcom/brcm80211/brcmfmac/bus.h | 2 +- drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c | 2 +- drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c | 2 +- drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c | 2 +- drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c | 2 +- drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bus.h b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bus.h index b5bb971..76693df 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bus.h +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/bus.h @@ -238,7 +238,7 @@ void brcmf_txcomplete(struct device *dev, struct sk_buff *txp, bool success); /* Configure the "global" bus state used by upper layers */ void brcmf_bus_change_state(struct brcmf_bus *bus, enum brcmf_bus_state state); -int brcmf_bus_start(struct device *dev); +int brcmf_bus_started(struct device *dev); s32 brcmf_iovar_data_set(struct device *dev, char *name, void *data, u32 len); void brcmf_bus_add_txhdrlen(struct device *dev, uint len); diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c index 3e15d64..5fb4a14 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c @@ -74,7 +74,7 @@ module_param_named(roamoff, brcmf_roamoff, int, S_IRUSR); MODULE_PARM_DESC(roamoff, "Do not use internal roaming engine"); #ifdef DEBUG -/* always succeed brcmf_bus_start() */ +/* always succeed brcmf_bus_started() */ static int brcmf_ignore_probe_fail; module_param_named(ignore_probe_fail, brcmf_ignore_probe_fail, int, 0); MODULE_PARM_DESC(ignore_probe_fail, "always succeed probe for debugging"); diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c index 372d2c4..b73a55b 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c @@ -966,7 +966,7 @@ static int brcmf_revinfo_read(struct seq_file *s, void *data) return 0; } -int brcmf_bus_start(struct device *dev) +int brcmf_bus_started(struct device *dev) { int ret = -1; struct brcmf_bus *bus_if = dev_get_drvdata(dev); diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c index 048027f..19db8f2 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c @@ -1572,7 +1572,7 @@ static int brcmf_pcie_attach_bus(struct brcmf_pciedev_info *devinfo) if (ret) { brcmf_err("brcmf_attach failed\n"); } else { - ret = brcmf_bus_start(&devinfo->pdev->dev); + ret = brcmf_bus_started(&devinfo->pdev->dev); if (ret) brcmf_err("dongle is not responding\n"); } diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c index dfb0658..5298582 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c @@ -4065,7 +4065,7 @@ static void brcmf_sdio_firmware_callback(struct device *dev, sdio_release_host(sdiodev->func[1]); - err = brcmf_bus_start(dev); + err = brcmf_bus_started(dev); if (err != 0) { brcmf_err("dongle is not responding\n"); goto fail; diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c index 2f978a3..d93ebbd 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c @@ -1148,7 +1148,7 @@ static int brcmf_usb_bus_setup(struct brcmf_usbdev_info *devinfo) if (ret) goto fail; - ret = brcmf_bus_start(devinfo->dev); + ret = brcmf_bus_started(devinfo->dev); if (ret) goto fail;