From patchwork Fri Jan 12 07:44:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wright Feng X-Patchwork-Id: 10159731 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 86800602A7 for ; Fri, 12 Jan 2018 07:43:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7860228682 for ; Fri, 12 Jan 2018 07:43:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6B5A028712; Fri, 12 Jan 2018 07:43:32 +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.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,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 A44F228682 for ; Fri, 12 Jan 2018 07:43:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754488AbeALHna (ORCPT ); Fri, 12 Jan 2018 02:43:30 -0500 Received: from mail-dm3nam03on0115.outbound.protection.outlook.com ([104.47.41.115]:31295 "EHLO NAM03-DM3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754449AbeALHn2 (ORCPT ); Fri, 12 Jan 2018 02:43:28 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cycorp.onmicrosoft.com; s=selector1-cypress-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=h6Ib2uF15CAohhUJ/eR2vb/F/ya9XatxZxYAogN4br0=; b=j6V5gITjqGf50zcMDeWWk7QaPe1iZl1pp4Jjt01J/kUvcbox/dak91vJwmapxvAAFBv2ajxhNQwN93G+W68+xgbgXvEV6lsMzzq6TDIbPqOAIjh51YUYGrAvQ6+0gsKVggZsR1/uk0BuuIONPfHIxtz7b9Jci3y4f/XU8B+jJMM= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Wright.Feng@cypress.com; Received: from localhost (61.222.14.99) by SN4PR0601MB3597.namprd06.prod.outlook.com (2603:10b6:803:4a::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.386.5; Fri, 12 Jan 2018 07:43:25 +0000 From: Wright Feng To: arend.vanspriel@broadcom.com, franky.lin@broadcom.com, hante.meuleman@broadcom.com, kvalo@codeaurora.org, chi-hsien.lin@cypress.com Cc: wright.feng@cypress.com, linux-wireless@vger.kernel.org, brcm80211-dev-list.pdl@broadcom.com Subject: [PATCH v2] brcmfmac: fix CLM load error for legacy chips when user helper is enabled Date: Fri, 12 Jan 2018 15:44:16 +0800 Message-Id: <1515743056-8109-1-git-send-email-wright.feng@cypress.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 X-Originating-IP: [61.222.14.99] X-ClientProxiedBy: TY1PR06CA0015.apcprd06.prod.outlook.com (2a01:111:e400:5972::25) To SN4PR0601MB3597.namprd06.prod.outlook.com (2603:10b6:803:4a::27) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 55ce7165-cb06-410f-87d4-08d559902a62 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(48565401081)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(5600026)(4604075)(2017052603307)(7153060)(7193020); SRVR:SN4PR0601MB3597; X-Microsoft-Exchange-Diagnostics: 1; SN4PR0601MB3597; 3:S+Mp6J+B8tl9UQtwVWz0RJ432PfUdaz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9rx2k2CWac6lJrcxZNuB3XKLG8NZcswG9Pc3SUt7gsL0eeTAsMIg1ty35CFnbRYA1dYoRbDk+yah9EnwWKVGfxwyr1B653gpE3EGq9AI4epg2MGaO3TRyNLKPlBpPhZ3Ku1TPp7/VwRU5SvmZYP/3r3V3BjaaTsntLnQ5AFJ9vY19VeWunT1cml2njP+Rt1k0SEhjR+WiYchvONFOxi19FPl405MTQP/JCVBgjqB+omdA2oRGIvFWGFXDPG5lmeCrK8IUEjLOcV9NJ6Y+7uGKNMFyAS7N0d2bs6Au6kZmlCgfT0O7Mhpl; 4:24s4MrgI8Sl4eO6zJ2/hcQi0rxwxXj4pprAzVX8hl4e6QkuK5Rhp/ipjwJdYCCVb1fnaPX6M91XCTcrGz15dhz0IOthVWlgtClfwUHbYQxLCMXJ1rQ5WtIsWDTBLCsJZSZWYC5T3IvpBOojrIzNtVATH3TkCXxW3EbHc9Z0jf/lBL5WhpF9EmMcbRcWqPc3EpfLobW/2DXbWYk1lgGA1YijEoEGmqsLQ2QKPnxsOj65WdgqaT27UIAR+Hkks25mWGd/f2nJO7AB6R14m49YoQ3LD04JDF2IKOC48YiCYabSQKp/ePogW5QtOP/55g+WX X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(258095267146985); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040470)(2401047)(5005006)(8121501046)(3002001)(93006095)(93001095)(10201501046)(3231023)(944501075)(6055026)(6041268)(20161123564045)(20161123562045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(6072148)(201708071742011); SRVR:SN4PR0601MB3597; BCL:0; PCL:0; RULEID:(100000803101)(100110400095); SRVR:SN4PR0601MB3597; X-Forefront-PRVS: 0550778858 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(6069001)(366004)(396003)(346002)(39380400002)(39860400002)(376002)(189003)(199004)(97736004)(2906002)(47776003)(68736007)(3846002)(51416003)(6496006)(6116002)(8936002)(50226002)(16526018)(66066001)(16586007)(81166006)(6636002)(5660300001)(478600001)(6666003)(52116002)(105586002)(59450400001)(386003)(316002)(72206003)(305945005)(48376002)(7736002)(6486002)(50466002)(81156014)(36756003)(86362001)(8676002)(4326008)(106356001)(25786009)(76506005)(53936002); DIR:OUT; SFP:1102; SCL:1; SRVR:SN4PR0601MB3597; H:localhost; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: cypress.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; SN4PR0601MB3597; 23:jbSvJ19sWuBIFHML4e6LAjxpHTsS4mXBTZek1EZ?= =?us-ascii?Q?j7vAhWtGM+PWn6AZM8I1YOme5SDg7as+2APON2GV77jiiaRRxcrvkFi0E/UI?= =?us-ascii?Q?9/4X8me9STIBEVPpguQylAJTlJGW2/9AW+jyQEW3bx/Yk/G0NxLgJksQ0CvG?= =?us-ascii?Q?hk5kciMWJY4cGWkI8hOBg1BVY7RRtlOipi/ZGRyPlsfiKRRvSyX3yDPs/6IP?= =?us-ascii?Q?liVBJBXQPV3Byoqlmm1ZwFBW/vbBMGcU2xmhvHbYLZhpQTI8yQqDa4P0WsOr?= =?us-ascii?Q?DiKq3PMuIybvJZa7FYNiijyStydBWWgaW/R2dvVjR9BV8i2oQXwbBmMdXgCj?= =?us-ascii?Q?fW4CVtExpam7Y5UCPGHEnMQrGPNmTtgXbC9qBup7uCJHsgFMJ9+s1DspYlU5?= =?us-ascii?Q?zc7ZcFLZgJRYLy4f6ZrtbtJxi97mZ2WGthco1B9RNQJDSm7zVu9Own3bXgww?= =?us-ascii?Q?0IGVbIrSqVXGuyPxNgvdvFwZdwy42Fg5kRBO5cKcWs67zFd0JIMoLhDQ6M1t?= =?us-ascii?Q?Yy0wmSNJoqRlieCNPW+pV6NOpqBqQi2LS5oAZkuuIeLC32W1Ee9fTUaVFzSV?= =?us-ascii?Q?SjvdizufJEc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+5DG4nGCLhWKvTpgHJupeng4ri9+GbudbFCETBfpjTAz2G1O3KywdCEVIWO3jc2jkszgeSziqjEdjRbxWoLMuINIbplB5VkYVnzJhe9ZcZjWkO3nvpxAKjs3YwPiKb5HP6CVCELlDSf6od8=; 24:D0YyWlhFNsgk4FSZZT7XFGywdJEUEq28+9q/bByfu1s/hhcIQEtN31CqAaHFfGIlGmK1NFkCRWtpf/Gh6+/mqQC5YvhYydbJibmN50onaRU=; 7:WF3m/nx2mKs7utE5BmNrx97TUowXRWURyzRWLB2Rr1qBcm4w0kN1WoTaZm1cMn0QQx3bPDFa1oaYBy9tSlpfKnRrRvSFGopN1QkqXrk8B5iNeOZf0yjBd+xjMYdo7jrpAZ3X5zcsigC0af0TYN0SjvR0f2/Co6dcERJkWNqgKynkVFPvIBBW7C3ISlNLGbSWk2Z9Y8kdpPWbvB6/pYXG+U/CeG0BOH2jaFlIYm5yVLSysP2xR2cxNdSTfLgeJcMf SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: cypress.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Jan 2018 07:43:25.9368 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 55ce7165-cb06-410f-87d4-08d559902a62 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 011addfc-2c09-450d-8938-e0bbc2dd2376 X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN4PR0601MB3597 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 For legacy chips without CLM blob files, kernel with user helper function returns -EAGAIN when we request_firmware() for blob file. In this case, brcmf_bus_started gets error and failed to bring up legacy chips. Because of that, we should continue with CLM data currently present in firmware if getting -EAGAIN when doing request_firmware(). Signed-off-by: Wright Feng --- v2: remove retry from patch v1 --- drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c index 6a59d06..0baab4c 100644 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c @@ -182,7 +182,7 @@ static int brcmf_c_process_clm_blob(struct brcmf_if *ifp) err = request_firmware(&clm, clm_name, dev); if (err) { - if (err == -ENOENT) { + if (err == -ENOENT || err == -EAGAIN) { brcmf_dbg(INFO, "continue with CLM data currently present in firmware\n"); return 0; }