Message ID | 20230713080807.69999-12-frank.li@vivo.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a6b2:0:b0:3e4:2afc:c1 with SMTP id c18csp1678128vqm; Thu, 13 Jul 2023 01:39:17 -0700 (PDT) X-Google-Smtp-Source: APBJJlHmsDKviiNmy1yzXerLhmz8ZeMJ4rWfkeBx4A/V3biZl+JiO47q1YJjMBb7OId6B3UNNrNO X-Received: by 2002:a17:906:100c:b0:992:3ac7:a2da with SMTP id 12-20020a170906100c00b009923ac7a2damr871681ejm.30.1689237557021; Thu, 13 Jul 2023 01:39:17 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1689237557; cv=pass; d=google.com; s=arc-20160816; b=f6TRxy/ziUEVHjv6Cdw+sCSIC4gs6+UD8Z/R+ofc364r716WwG9/+4HMo7JSsNTTnH 7/SvRU2wJpr8wV1aHSVNqot+sw/YOPdnvI7WzHwyfqDXeHxZHZgsmq3uiF+qUqFKXOjR Z6vfHAXylFk58vOnRvnOD4o3gEFSL3UOzTBQm1UMuXBO8QEBqShGP9O8/i3at/+uO77S QP8qupL/CqpXPqfwbFhyKlJhywBV1TqiIKbqJ6K+WL9epK1uP1EeP7zpx7p8M8AxR5nO +TBED+9YNv8uf5jA/li8TePSXaiT0f6Xz0QIy5qgMEPLHGyURm4jWBoCzjmxYuKTNW5B X0tw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=zfkki4xoknH9pl2wMgN3/myZCKUOHnsaDhrfpsUGHGA=; fh=fKMVcxEXyR448PAR0ORcEmkzL5SqNRft7iKHS6hwUKc=; b=NT4yBzhfr82x+aSfhNturLRL+J/7Goq/MkpPFmKEkPobvBxxOucpZvyI3o2tKf3pWE 3LRutcs607BCcl2rG5cVV8BDFp/oNec9SRBw9JHuFAxBRaSGVfOZ2tdzqznpQctkb9ru RciPZhpIeyaYyEIrKe/963qiUri0XIREGK8VE7+Z385u4PMrYbskJQ/k9sYTMsdG/3qx fi1s39HE6ZwypaIywOyXo7fnjrh0delJZmMx6sxS76U1PYhXrEeeXPENsMOwOJBIBj7E O6X6asnZPHhh6ZDNJRMokmc+71Xkq3JOXR7WgOOPUb39L4MI5QDmvyLfrUIpSbL07wxe GN6g== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=LcGG7SrZ; arc=pass (i=1 spf=pass spfdomain=vivo.com dkim=pass dkdomain=vivo.com dmarc=pass fromdomain=vivo.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=vivo.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h5-20020a1709062dc500b00977d04a8fd4si6596348eji.1054.2023.07.13.01.38.53; Thu, 13 Jul 2023 01:39:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=LcGG7SrZ; arc=pass (i=1 spf=pass spfdomain=vivo.com dkim=pass dkdomain=vivo.com dmarc=pass fromdomain=vivo.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=vivo.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233994AbjGMILH (ORCPT <rfc822;ybw1215001957@gmail.com> + 99 others); Thu, 13 Jul 2023 04:11:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49598 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233984AbjGMIKA (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 13 Jul 2023 04:10:00 -0400 Received: from APC01-SG2-obe.outbound.protection.outlook.com (mail-sgaapc01on2115.outbound.protection.outlook.com [40.107.215.115]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 42AC6359D; Thu, 13 Jul 2023 01:08:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=n8NcePqu9UGPJfWCI0D4nAukeB4NlnuF4KIDJzWBoSU6q1qQo3BobqlXnwfinetx8OFjy2iHQHPBXQ1O0xQCGNKmsEGExMvtqGTjKoReSMXdwicn/egkIkoiVbeXjrpek4/MOULCvCQX/PxP8BuL4WktM8grfVHvz/IXv619FChZ3UDcl0NJjLs8u39xsMnukFjMwthmsRF5KcWAE1+0WS0yVcwZ0saQeidK90YCKh75akPef+IpBjSgPsZ9XXRZKE+Y7IGkhmLR2r4+QGYXV2bIMtmpMYczbnErrBEYmCCiUrLVlTKeVAhccMbmrDUtXiMMwnyqEtokgF71UtaUXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zfkki4xoknH9pl2wMgN3/myZCKUOHnsaDhrfpsUGHGA=; b=YVm7rukifl1ZWnwIlvnl5HWgMkeIi0ZthyGBrF/StS3cDj2alu55YTBD6/j7xwzNNRajYOp4BXmGfT5ftHtQQB/mhKz8AfRDVV6uosgzyqNhkolaHlvodklyZg3Cj/feUtY3/k/u4o8fQfeV8iAwRul40gZIJFLuzjLbZGSxsM+qvGQ+JGxP+JElxl27gwhU+LDzfq6XN9llfvC+YszMAIyPNuDblQHrkWinaw9MFNsVj3MNrq1KzzFkx5y4NthuA8ZFNjyN75trKHNuuA+wjIw9/jYpUgTtp762KSaWikxd9ZuZIWMyPxaI2C2Abey8tO+LZoDYUkstd6cItn8j8A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zfkki4xoknH9pl2wMgN3/myZCKUOHnsaDhrfpsUGHGA=; b=LcGG7SrZYcjK1Rh44RUAQApCvsASkb5luXjdRlQEwmG9/gPn7hlng8CBrRcKyqjFP3h+urq9cUt91DnM1AlwT/SN2jBSPh72DQK0BM82x708AB05LZpUdFin5wGNv0jZ1TdJ2EmKibmrrjC57nnijVnRr63qy4bn0zM00mI7ONFpjS6rZxrTeIfJKdRs8zA6xt4vIgdY+yxlqvlL2N1lGmxSsXuzkyC3+8HggmelraEC7eCEamGlCGwDk8kG8Hc7vQFyDc4eJ6mnUvjLm2YBrKKGWSYC6BvIxvIK4hsx0keWVPE00a1W316980YExybLvb6Po5Pq9iL5SZBcuGQewQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by KL1PR0601MB4371.apcprd06.prod.outlook.com (2603:1096:820:74::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6588.22; Thu, 13 Jul 2023 08:08:40 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c%5]) with mapi id 15.20.6565.028; Thu, 13 Jul 2023 08:08:40 +0000 From: Yangtao Li <frank.li@vivo.com> To: Adrian Hunter <adrian.hunter@intel.com>, Eugen Hristev <eugen.hristev@collabora.com>, Ulf Hansson <ulf.hansson@linaro.org>, Nicolas Ferre <nicolas.ferre@microchip.com>, Alexandre Belloni <alexandre.belloni@bootlin.com>, Claudiu Beznea <claudiu.beznea@microchip.com> Cc: Yangtao Li <frank.li@vivo.com>, =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= <u.kleine-koenig@pengutronix.de>, linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 12/58] mmc: sdhci-of-at91: Convert to platform remove callback returning void Date: Thu, 13 Jul 2023 16:07:21 +0800 Message-Id: <20230713080807.69999-12-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230713080807.69999-1-frank.li@vivo.com> References: <20230713080807.69999-1-frank.li@vivo.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-ClientProxiedBy: SG2PR02CA0091.apcprd02.prod.outlook.com (2603:1096:4:90::31) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4371:EE_ X-MS-Office365-Filtering-Correlation-Id: e8d836c1-3e99-444a-e801-08db83785e1e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 5Qq/bmvFN4VlDrj7TKH1XCVkVsf1DRLd1vvKRGAyJ8R0zlI1FJxGK90tpGHebsEcUOt6lJXBwAeH87p7/rkxClIxcoO2XApk3NPXbsadohJTa81RomypoBu/ps81CO4IhVKa7rTFNA4toCNItTArtgBlnxtV9cS430VuxCxguic9gzYgANs5fHL0rsn9nPKcEB4nTBNvr+B2+Y5lRYFyB7rY+SQgWiD4OPpV7YPiQxJ3zYolIdgN+EoUX40dWRLJpH/9Rfoggteeu1iuOtpp8FYOnA/uAN5xrRiVdzGUp8lO3y1HH3GPuQC/WC10UxpfqbzsBNZxxtYqC7QfyY0bJ9Cm3lU7rZm+qxUWTmIo4AHqez+DbI84w7rncnbeSAZKuHnGXSJr12ApFdRx1OrRiPjfY3+298xSzFcnueomKAl/36PxrGEIC9wnuECF16rFJQV2uxol9CukU/FmygePxHADSuiGe/Au/8c7996H/3gZ+fIEwLcxX6fvyJBX4lugJAu5dw8Dol5pFAbO689Qjeqnr/pOztJ6TDNUC0HPicbufQ9vJ48jCybcG6zo87n6Qtw4ZctHPY3/BvbyN42qMqCs+EGXSHSHeTSciOEnwO1pp0pTSLLfKwNehHprwa0kb9DGbwbJqn6OVjUPaQVcOX1jjhgQOeIZZbyunQEfMWs= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(396003)(136003)(346002)(376002)(39860400002)(366004)(451199021)(38350700002)(38100700002)(478600001)(4326008)(6666004)(86362001)(52116002)(110136005)(6486002)(54906003)(66476007)(66556008)(66946007)(316002)(6512007)(41300700001)(83380400001)(186003)(2616005)(2906002)(36756003)(8936002)(8676002)(26005)(7416002)(5660300002)(6506007)(1076003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?laAUwIS9U03fNZEszNQY5GEb2coM?= =?utf-8?q?UJd1KXQAGnJOqxFqtLRb+DpSeogsyuoRCPKaYSCQZ5dd9OdqsBs2zIJ5DdltBRO99?= =?utf-8?q?lNAnynUgEGjFt1dBkaXtvq8oXZTfZKYM44jotNLldFQneFERHjY98M4AEXdIr0tbp?= =?utf-8?q?cBUEXvVc3iRhz8Lr9ebc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y8BTe2NO1pDEWQ+b7TECt/KoMACg+/KwojDo2F2?= =?utf-8?q?bmCd9jO3DyDjmMzRYAVUQjUXFbEJqnev+8cfDqKcXLZ8cwp1Cv8O1xivRfVuz6Xw/?= =?utf-8?q?AepWlkXBau7eIdgOd8Kx8yCRpuUTeVovNEMHq0sjS1YlAyZLxyKwiT4zGNZqZKwD/?= =?utf-8?q?adH+zzsGNXI0BGSgIHPp8ySycnwc/LlkOO3kP+OG0cUVNpW/BwZQkJ625w8j2TTBG?= =?utf-8?q?94xBjQgh/wgNc/UarNOFmH80BAkccYJHaatLrf9rkpjauhDdOr3mqtmznxH7/d/RK?= =?utf-8?q?qZEdqRR4xm2KYQr8GVFLi2m5wlGFT6tSb4ahE9FhiWx499etVJJlzJsORtrT84TWJ?= =?utf-8?q?STtUOvQf51SUSYEqYIFwZUSTO4C0zCfYC2p2Ug/GsZveoHRAo0Xn85aqKDAniN/Za?= =?utf-8?q?6rS6O2y+esjp2l2wn9vYvnSafIuQWtwLpb4sBryrinp9G+8hkRfK0VWn8h5MJlCzi?= =?utf-8?q?UkQ0/IszNf/M?= X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: e8d836c1-3e99-444a-e801-08db83785e1e X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jul 2023 08:08:40.2740 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: nnQXMIMJWNBS2EPq2fnGm0M78YBHwzdiL5JE/vUfN+csXfRSSvXkb4zBnYng36rHIxny9c+O5EmYZiEAVHsYPQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4371 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1771293960648279172 X-GMAIL-MSGID: 1771293960648279172 |
Series |
[01/58] mmc: sunxi: Convert to platform remove callback returning void
|
|
Commit Message
李扬韬
July 13, 2023, 8:07 a.m. UTC
The .remove() callback for a platform driver returns an int which makes
many driver authors wrongly assume it's possible to do error handling by
returning an error code. However the value returned is (mostly) ignored
and this typically results in resource leaks. To improve here there is a
quest to make the remove callback return void. In the first step of this
quest all drivers are converted to .remove_new() which already returns
void.
Trivially convert this driver from always returning zero in the remove
callback to the void returning variant.
Cc: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
drivers/mmc/host/sdhci-of-at91.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/mmc/host/sdhci-of-at91.c b/drivers/mmc/host/sdhci-of-at91.c index cd0134580a90..af5bc0caf29b 100644 --- a/drivers/mmc/host/sdhci-of-at91.c +++ b/drivers/mmc/host/sdhci-of-at91.c @@ -443,7 +443,7 @@ static int sdhci_at91_probe(struct platform_device *pdev) return ret; } -static int sdhci_at91_remove(struct platform_device *pdev) +static void sdhci_at91_remove(struct platform_device *pdev) { struct sdhci_host *host = platform_get_drvdata(pdev); struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host); @@ -461,8 +461,6 @@ static int sdhci_at91_remove(struct platform_device *pdev) clk_disable_unprepare(gck); clk_disable_unprepare(hclock); clk_disable_unprepare(mainck); - - return 0; } static struct platform_driver sdhci_at91_driver = { @@ -473,7 +471,7 @@ static struct platform_driver sdhci_at91_driver = { .pm = &sdhci_at91_dev_pm_ops, }, .probe = sdhci_at91_probe, - .remove = sdhci_at91_remove, + .remove_new = sdhci_at91_remove, }; module_platform_driver(sdhci_at91_driver);