Message ID | 20230713080807.69999-31-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 c18csp1676484vqm; Thu, 13 Jul 2023 01:35:25 -0700 (PDT) X-Google-Smtp-Source: APBJJlGXlRBWHOQwnsVSWehArgT5AUksaEq86yJrkROPB84ZRl6gQUhO3GdPbNy86LcWx2ulcL4i X-Received: by 2002:a05:6402:1210:b0:51d:ec25:ce38 with SMTP id c16-20020a056402121000b0051dec25ce38mr1182561edw.10.1689237325367; Thu, 13 Jul 2023 01:35:25 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1689237325; cv=pass; d=google.com; s=arc-20160816; b=PS7WXirTHzVpJi1/2adnhxLgpDNv9N/BNqUgEi7tTZPOWqB8DkmkcONdrJanyWGJMU naZHlMW0G0iMhwhptkpLnlXK6KedKtQ2cuJcV5V95bqbJmJCFMywHBtQFTSrCid+7gVF ALK4/87N0Xpq6PaZjWb8cgp8l/HQoCxnUFQ6rwVNHdbvjoKypxbNI0oQVdSSh+KRDc/g 1WG8VR1CBLVX/BsF/mFRUczvTF6bQ/6viNZHkEiitgjO4QvvpYUGbmQQpvsFDSTOBqJh 0Y8s9FOZSvP8Ir340Gb7RLJDHhDCZXW5NXebTC/IEithU4RQWBDZNw5weXwublNqfm2F MGXg== 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=VPvk0BJvyiqypQQEM9Xxs52SCa2gV2Is6nfaORO6Mdg=; fh=ZYodWTe0KCUO3NR7BtRFAqGMu45kjt7wn2F8buQXmlM=; b=J/FaAwU6FvLWzsT00TUNLJIcejKoKiYuCr1t7Ojovp1ZZQY1HBO1PXhXDZyW2gFLzf ELLqrDDDTYGFlYzhCCMAFa8lt6nu/dN+aFm4ZP7VfG4q2Pqe2eIz8BVPyBpuQv5qVjVe FCIK9c9xsiWPFhlMMSUHpBo5xVM5c35jm3/dQXcRu7VDc6LYXXZ++gyftIted0cgVYmS hgXxeMTkE55KL+JYmspax6lNARUQITS6eQ5aJUfgi8IiBirBAcjy2w0sl8H+ArbwrOC9 qMGvx5/l3WKLvbPuneTnfpkc7393NLWONLkcbe3myKB+tY1Y5wFbfvpHGzXWnnIlR0c+ TRBA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=g4rgt97H; 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 m23-20020a056402051700b0051be9a93243si7128386edv.153.2023.07.13.01.35.01; Thu, 13 Jul 2023 01:35:25 -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=g4rgt97H; 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 S234366AbjGMIMr (ORCPT <rfc822;ybw1215001957@gmail.com> + 99 others); Thu, 13 Jul 2023 04:12:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50328 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234191AbjGMILZ (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 13 Jul 2023 04:11:25 -0400 Received: from APC01-PSA-obe.outbound.protection.outlook.com (mail-psaapc01on2119.outbound.protection.outlook.com [40.107.255.119]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9AD322D77; Thu, 13 Jul 2023 01:09:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZRGMwM0JKd+H5GT+yki5nztO+hhO0VG/75ghU50IMStwQK5s4bd3MFQuJuf/URwTBZ04U+S/KR8hDnJM5EbCnVo7ju+EN+pSyBCGwc14SU4hqI74iKtrnhfL7KB4pcsKdraxDTytOMnZXQ/eyQlcHS+1jW0gp4Y3b1rURr/By49aFf2eNoiIydnIrwZLZ/gkSgFqrBOg3lFIlLwh6qsSm4LBJc8MYUvTlP6J222FPCg4GXmTQZGDEfQts36Lc0Bwp7k9+wuto4sBGKMM2LUk8uO4EkmA7R0ckJz56F96rsv8REKQn14qPrOTsMxR8W5MhsycB0yzo53V9VSGzqsyRA== 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=VPvk0BJvyiqypQQEM9Xxs52SCa2gV2Is6nfaORO6Mdg=; b=gPMMnw+GKOExmdo0smoZA2SGtONWKOzBRrvo4r3xkEtqJQ7KLHPLu3nwE8fXRJ7WARtnC2wZix9Ds+q7yu0qXnZuHe/NU0VruLhLh0HmDPNPeQoGCEujH09lBxQUNPQ0blTrdQkTEsFDPgQZwev/IbkEaHzA/aEyYZnt6Jmr4QjxQl2GIsWIkR2UyF6P3jxlFSgLAYJH7b673gG5F+w3mbtABmWkv9nIhuddmuRz+RZBfQcgFMCa5dNuffI93vpCcASvjnWDo5OVxCU2egNZ0kMxBQ9e9xRlaQVouwnZTzNH3uGvq4xLS2QBrzUgdUvSyvwauCaej66OQZCko5jD/Q== 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=VPvk0BJvyiqypQQEM9Xxs52SCa2gV2Is6nfaORO6Mdg=; b=g4rgt97HIo5oSIjhuUJ1sEbaUzgdgI7EBSPTrjlmOFrMwaAhjK39oz4KGcJbsVmzddBIfmug27msDutCxvFcVGnWWKfSh/z3kFn5n4kRUDGGQQKBZb0B/b80eN78LRR/kIfJ4swG8X74mlW83+AeHoj+/KxV+9IfNseQf2JEuzEPvLO+OGDoiR2bC51H0zrihsMSPwnAOOvltwzjaLKLLYaI+FWsujqSXniPvd6pVCIb/gNXKMv/BN7QFwx6apAhQmQvpOvKxbX+8Y+sMxOBZJ6TDAogu0KbVVbHW5Qp47nTYOdjJjvQGnscxu9onAwCwdi54Q8Vtl5Yuy5bZY92MA== 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 SI2PR06MB4409.apcprd06.prod.outlook.com (2603:1096:4:15c::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6588.24; Thu, 13 Jul 2023 08:09:14 +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:09:14 +0000 From: Yangtao Li <frank.li@vivo.com> To: Ulf Hansson <ulf.hansson@linaro.org> 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-kernel@vger.kernel.org Subject: [PATCH 31/58] mmc: pxamci: Convert to platform remove callback returning void Date: Thu, 13 Jul 2023 16:07:40 +0800 Message-Id: <20230713080807.69999-31-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_|SI2PR06MB4409:EE_ X-MS-Office365-Filtering-Correlation-Id: 8a5bc45b-c5a0-4143-7862-08db8378724c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Hk9erT/2dc6ezq8GqU85AE7qNsDVeqgQAlTavcg9QBfVb3JDmN6L3fGrdCl86ZaXT8TZETTW3S3mpHaA89OYm+eFWtZ1Ck5s/Y0Hp+2gVqqqBNVVKswzKQMgIaG3HbEMXd+fSDsWXE4TmjFwOrMEoAuAt5FRwM1xUGNwmwOYj4PBStv2b0RySEPiLSHB0Im6+ut92oUhtjtcM1mYWjr6V0LrvsNJmcuVHmRKTOW5XDI6wZxjJttlh7T3HUzG/JcouFrOhR3Gwi/S+09UUMzVTEVRuvMqgGr0ia3fTr7SNRqQ7eiB2nzpt1S0FtshWzpOp3+VQC2Per5fY68ETvAejQtUvPX74+MIMVTAtorfQjVsBwvetX5ipvO2AgCrTFf0jI8aDySOWRHgGtINt8MMj+d+UlBUeiFQ17DYOH5C6rGecnsLxVyLzxQixNadzdgoXI7/k/GjI+SrCzAjHn5jX0tYGBLBDQjUDgyZpHElrg59WWPyqJmXhnFH3pyL9KIkbhjVzIxNXYg6MBhxgZnKbokfgCkyiQzw0RPcaUt4P6WWsnL76MXDrmq8l8LR7CAq9abqPkhewuEEzc9O4yb84VDrqbBH87WLprqsUPOL460PazvS6LkrbCl4Z3PD3mCs 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)(376002)(346002)(396003)(39860400002)(366004)(136003)(451199021)(478600001)(52116002)(6486002)(6666004)(54906003)(83380400001)(2616005)(36756003)(86362001)(2906002)(186003)(26005)(6506007)(1076003)(6512007)(38350700002)(38100700002)(6916009)(4326008)(66946007)(66476007)(41300700001)(316002)(8676002)(5660300002)(66556008)(8936002);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?pZMr5oZgp5Olw+VXkDG8APfx6KwD?= =?utf-8?q?0r+z3RqlJ9gbn7SU+nqY1JGVXkt2lnTp/Qpha0+2TVIFtF6+3zW9Y08coPSqqTOJ2?= =?utf-8?q?uybgsGKwXsSC92Kky3Pu12o93gi3cHyet7AAP7GWmvZjHvSUCrQM7aaYm4R1Vwudp?= =?utf-8?q?sNG66fgOcPW0PyDBSCwMLzLb5SRyVy6k72/ov5YFCbO/QnzC8NihMeLcotAQCzbGl?= =?utf-8?q?1CPGFLmrWiAD08jaJR9imlCDiTtkT1013ifXYugLCGI3AaPvIyNNWDUSkhjvV1/RD?= =?utf-8?q?Pt9uIGo8WpIiCblQQl0ptPNeU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dI2gMbuGYfH9yif2OJsJCobbSO8pnhYF7JEFISl3?= =?utf-8?q?9Pl2vXo+o/dvl5s4TOxcH1f9/vK7wTEdWe2SOTvU1oLrWhm93rv44L/i3ytQGBC0T?= =?utf-8?q?QMFNEDklJfDD4dhMekwkX/DWfTtFV9zqK9PtOner8twUMx79h3G8mL6k2JmSlQXa+?= =?utf-8?q?nGqL3axI2MkPqmwhmBhhZ0Ug8wH2SQbP0i6I/TripyImInyypMKmbGHZaUJopTamn?= =?utf-8?q?TPnO7c7M7r4ekxLwP5r6nrioO/XhXg+kCjah/pCcDab3+ox3kE0FBhjrnARl6Zv3I?= =?utf-8?q?vZX1wKHA9CeDHc0q1FzEszwFl5fXHfli69Ayl6s9b5SiRFhvdlEk5TYjPzUPNfux9?= =?utf-8?q?pCvtSsAMIbRd?= X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8a5bc45b-c5a0-4143-7862-08db8378724c 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:09:14.1365 (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: IiIx/a69hJ0NdlU/3r9hqmn6Il+0J4Qi9KJtg0hJhS4IdAJf5+4FJ28A81P3HQN74LggdiWMu6M4P6AvcghvvQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SI2PR06MB4409 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_NONE, 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: 1771293717699806080 X-GMAIL-MSGID: 1771293717699806080 |
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/pxamci.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/mmc/host/pxamci.c b/drivers/mmc/host/pxamci.c index 2a988f942b6c..af17df545582 100644 --- a/drivers/mmc/host/pxamci.c +++ b/drivers/mmc/host/pxamci.c @@ -784,7 +784,7 @@ static int pxamci_probe(struct platform_device *pdev) return ret; } -static int pxamci_remove(struct platform_device *pdev) +static void pxamci_remove(struct platform_device *pdev) { struct mmc_host *mmc = platform_get_drvdata(pdev); @@ -808,13 +808,11 @@ static int pxamci_remove(struct platform_device *pdev) mmc_free_host(mmc); } - - return 0; } static struct platform_driver pxamci_driver = { .probe = pxamci_probe, - .remove = pxamci_remove, + .remove_new = pxamci_remove, .driver = { .name = DRIVER_NAME, .probe_type = PROBE_PREFER_ASYNCHRONOUS,