From patchwork Wed Jul 26 03:59:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 126093 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a985:0:b0:3e4:2afc:c1 with SMTP id t5csp180503vqo; Tue, 25 Jul 2023 22:04:24 -0700 (PDT) X-Google-Smtp-Source: APBJJlHwuPqruyzI+T/JmxhBV4ePAFJ3i3UsMK3Ozm4pnNmZcFKfI+BkaZHoYU61E2G+v9uS14c7 X-Received: by 2002:aa7:dace:0:b0:522:55cb:ad7d with SMTP id x14-20020aa7dace000000b0052255cbad7dmr721419eds.16.1690347864496; Tue, 25 Jul 2023 22:04:24 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1690347864; cv=pass; d=google.com; s=arc-20160816; b=PNVXA4gE8hR0qlGs7TUa3wtOLLBbVi+J17m2wnUDMccCw5GCwEBkb00W66mS0r9AbO bLzzYTvgc8KuzjpDw3fbO4HgGom9WsTcK3P0wfmbKqC4eYe77mlwWfckwCNo6kwcIukE idrCsdw0qYZJ+pz4o9dZbqAPly6H2n6nK/fDxt4a6DAAmjpRERva+7ZzS8/9xOhWfb/o GQ18i6iASB5lh8/q2q2sZd1pgvRYABFbeF8+9iaFTBUU7nohNcKrfx7q1ojHQDoPep6v trSOQvRnwOIBIQrgU/+/L0qBqT06cC42gSh3swI1Y2e3BBpqolEqSetrduuUkIjFAo2X iLjw== 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=gkUpr7l0pDttVGz3kqCsUAr3ho/CgWL/40WVT1faxUc=; fh=Fb6P30QbJmZZcgekLxd4O6Gwkug10RvmDkc4bghVWeM=; b=UEMudj9Nk8/F+8Ejo6r8RaDrmNKnP7kzcnToEKbqQzGnDuainrFS0hhykHHaI48+gT EvIfiRSzbuFoxFocz3wpRXoV025AzYxG1+4Fxl/zntwQhM/W2E41K3A4InM9p9jj2UwO fYEBWLQ+FWH68qJUEembIMZNjQz8TUlAr9C+59z3/m1Mb2WmhUraLVotYzCcBt2SeSrP UA7xjtkzggVJqW9zAq5zPHXoOBh//M8tycZpSBFSFuyoGM7/oKDC5EXRwf2mgCmOAUzb 53/laRGUwmsALlGJJBQ5Rmxap+PGCYccV9AFQO+1ZRqor+cWiMNs9O0mvt/mObVJcglb NsEg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=SRBEHQla; 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 n7-20020aa7db47000000b00516a1feabc6si8618118edt.657.2023.07.25.22.04.00; Tue, 25 Jul 2023 22:04:24 -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=SRBEHQla; 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 S231579AbjGZECr (ORCPT + 99 others); Wed, 26 Jul 2023 00:02:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55508 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231300AbjGZEBq (ORCPT ); Wed, 26 Jul 2023 00:01:46 -0400 Received: from APC01-TYZ-obe.outbound.protection.outlook.com (mail-tyzapc01on2120.outbound.protection.outlook.com [40.107.117.120]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4AD3826BE; Tue, 25 Jul 2023 21:01:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DY057Tfhwgdy0BUfSC9gZwNAeHnb/t9YvFPpdjREDiaHiHeq1oE/F+0SRE/TJHUet9wcTRuEQPa+7I7Hk6W2p4TO25r7hM96jGigf6h9pJ72gOtIq2vm/CCh+1ikxn6ksjC02XewxonJKsGLMXkJCutHmEmHh9TW0joakaJOgdCq2EqJ0S0Fsulm+Z7/2MvebzCX+gQGNpuRMyRApFtKbkVKusA1gDmb+q33JC20IeRJXHrR/0BKavztccsOC1pjWcj6iMgm6p9aVZSLJRsnUezmUNTRqLwQJqwV0Tdr4nI+0lHNfNfEQxwx/hN3sK0ZHApcR98+HSbaumv7tuh+4Q== 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=gkUpr7l0pDttVGz3kqCsUAr3ho/CgWL/40WVT1faxUc=; b=OqqFZ1+en6kCqadR+K9gqTU4KMnMEr0UhAUnsl/xopgKNKnonUqpAaWN0gFGy0SF8jRw0fDMaIY/O89DzfKmL90iomU4H640RWsrTF2yLUrBOL1DEj+dnX0yqapKa/0BOX+I5WnUrFBnH18N7asH+faKZZNk5Nd2byXnmM8XrgrKtMPd+thTvl1SssdpMO5/cuVLxkrBho4YH1A1aRg8M96upNLmBZWeokKW2YGxpkNB93Dc9H8ICP5KarGw796yahRSAm5hw9edpyEpr/Soj8GXJvWifGMmtdrOQ9zF2C8C76n0oLeMp82TGmpBTemYdLBD+LV1MVq2mvUTGLD33w== 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=gkUpr7l0pDttVGz3kqCsUAr3ho/CgWL/40WVT1faxUc=; b=SRBEHQlamksChbKgSfHcY1AqxC/Ij6/BdidGTaxV+EQleUR8zhqQnd4dt0C6A4g6s+w5Gv7br71NSF3GVNu8v4zeqYLA5MQCJInlEsb+jVBOfWHcv73XYqXjmglbSDwwdOcNvxCUbMOY+yQq6BcNiikWCeIIoQSBEeQzGAw9Oq8h8WJ638NpBmNdzx0/yjkcCK2/ySsV7DXXsRz/9qxTi1mSHjH01YxR+DagpUskJv8eGA3Bt04cJfQpvxQw/gOhJtHEcp4jvcKnXijWC7G9/X5zhO8yXwKQb3SpO2SRPVC726ZT+Y0X2yzMIt6FfKfa7rtksCkOFQ7N/IA60IYGDA== 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 TYZPR06MB3934.apcprd06.prod.outlook.com (2603:1096:400:7::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6609.33; Wed, 26 Jul 2023 04:01:22 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::732f:ea1d:45a1:1e0b]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::732f:ea1d:45a1:1e0b%3]) with mapi id 15.20.6631.026; Wed, 26 Jul 2023 04:01:22 +0000 From: Yangtao Li To: Jaehoon Chung , Ulf Hansson , Krzysztof Kozlowski , Alim Akhtar Cc: Yangtao Li , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= , linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 14/61] mmc: dw_mmc: exynos: Convert to platform remove callback returning void Date: Wed, 26 Jul 2023 11:59:54 +0800 Message-Id: <20230726040041.26267-14-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230726040041.26267-1-frank.li@vivo.com> References: <20230726040041.26267-1-frank.li@vivo.com> X-ClientProxiedBy: SG2PR02CA0093.apcprd02.prod.outlook.com (2603:1096:4:90::33) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|TYZPR06MB3934:EE_ X-MS-Office365-Filtering-Correlation-Id: 90722416-c551-493f-8c1b-08db8d8cf981 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: wX6EFvNIuIQd/649CJtu3yTHPnck52lzHQmccPYxKC14qYXI8SlBovs6aFAV/JT29q3doV5BnGud2fo9fgRze8yzbpeWydJXFHcoFby3sKppeQ1ckK/9J9oSmaDfqTQEO1ZhBOIXKP3ilHNqXfHdoEZpY+KZu6yWx32c3TtM9cCYvevGCGT+uloXnZeeVKnDC0zzOPghu3Zdm0yhK8Vhp08Bbo+9YWUoXADn4IX7BvUnquDKl61faitCFyIRvSOEyyS9DpM6bgB/PlmTXyI5z1u+5KAv0eO88rvTdtIq+ciKi1h0CJ6tLfWfWyjxB6zLyWW+vV4tPbD89oMae/fYR4okM3KbuBVdLMvKufQQyoFGzv6MncS8080PMF0r8KkQuaNMERQh6b7WDae85vVk7VZte/8wcYnv3EO1L6fWAnJEIwn/llPehqLrw7MDEQv9iKkl6NYDGRO7UA+VpqaDtpzgYQXu5yPKQI9s1RWTcrYSDzJnPHZTMhjch73DH7qamgu7MFk85SwvX30Sk8uDNBVHqGu63AwVXhQ4W9mzNRY0ctm/RqsqIIMORtADzdR/o1OFqQ56pwMAo/TUxvlwUhkIame3DDtc1gBH3mchbe6Phy+bvrrrdNClWfpBQrsf 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)(396003)(346002)(39860400002)(366004)(136003)(451199021)(66574015)(66946007)(66556008)(83380400001)(2616005)(41300700001)(38100700002)(38350700002)(86362001)(36756003)(8936002)(8676002)(5660300002)(478600001)(110136005)(6486002)(52116002)(54906003)(66476007)(316002)(4326008)(6666004)(2906002)(6512007)(1076003)(186003)(26005)(6506007);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?PcDvSZW1fuIx3dK0Xz+HZOLQaxMQ?= =?utf-8?q?GmqRnCV3P3VSAGuax4BqHWY1TrSrIUFD9Pv1HqtMHhcrSZ8Wh681TmVGTEs+zndz5?= =?utf-8?q?CYs0NRP9v2s0J/Wcty2wnOdo6M2gtprYDhRk2PRR4slP5hDR6CG2w3qu28iPIXfRg?= =?utf-8?q?woMiPHxpYnNC0MOW16K7E6buwlPPgpXK/3i9B0siZ4xJ9x7kGFdtN0u4iJEdm5xr3?= =?utf-8?q?JGzayuxg2kLxVqbyxtXuIDZJvLmQ3Le1jNXtKhTALRUE4cbbWvMIWGMyO6GhShx2Y?= =?utf-8?q?SOjFA/d1GzVkBkOfbgG1a4/PQVxXZgQnPV1YeXRmGvvHxTY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tFR05B5oRfeOAuKGk7?= =?utf-8?q?o1qI5iwdx3qAB3TfXBb0+hW5nxLp8jfR5wfr8Gzxjl/UcXBgWO5uCJpRtHJiJTLDq?= =?utf-8?q?wVJOdndb1llm2337BPCgNupKkayD5Bymd5eXB+/Ig08d99JIYPcY+CCylASN4OvdW?= =?utf-8?q?lYVAIE2VJNVcEyMDB2+JEew+KLJ07dMCnllNFDy63MfOGSWw7b4x9OHHxE4tgNKWi?= =?utf-8?q?qmeBXhKUBh5NTScOJ6BiaRz8Yc1lBTue2D13vXotedXSGyaU2zX2724HAQhw/P5sI?= =?utf-8?q?6wtVJ9Q9T+OV1PYgXE3LZNCyoaCbOczSSpVzY7S9b2taxgkqrPYwVatfueOpUGEEz?= =?utf-8?q?SNyr91UGCdRY?= X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 90722416-c551-493f-8c1b-08db8d8cf981 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Jul 2023 04:01:22.5419 (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: un1xXXYFNLo+qJhvyWWu9J/Vqx+QAWFJCNkKIO2pQRRnSdYZWCw1tJEMlY7TGD37GfxXfldPngq2OBpc3Ocnqg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYZPR06MB3934 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, URIBL_BLOCKED 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1772458202203659654 X-GMAIL-MSGID: 1772458202203659654 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 Signed-off-by: Yangtao Li --- drivers/mmc/host/dw_mmc-exynos.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/mmc/host/dw_mmc-exynos.c b/drivers/mmc/host/dw_mmc-exynos.c index 9f20ac524c8b..698408e8bad0 100644 --- a/drivers/mmc/host/dw_mmc-exynos.c +++ b/drivers/mmc/host/dw_mmc-exynos.c @@ -664,15 +664,13 @@ static int dw_mci_exynos_probe(struct platform_device *pdev) return 0; } -static int dw_mci_exynos_remove(struct platform_device *pdev) +static void dw_mci_exynos_remove(struct platform_device *pdev) { pm_runtime_disable(&pdev->dev); pm_runtime_set_suspended(&pdev->dev); pm_runtime_put_noidle(&pdev->dev); dw_mci_pltfm_remove(pdev); - - return 0; } static const struct dev_pm_ops dw_mci_exynos_pmops = { @@ -685,7 +683,7 @@ static const struct dev_pm_ops dw_mci_exynos_pmops = { static struct platform_driver dw_mci_exynos_pltfm_driver = { .probe = dw_mci_exynos_probe, - .remove = dw_mci_exynos_remove, + .remove_new = dw_mci_exynos_remove, .driver = { .name = "dwmmc_exynos", .probe_type = PROBE_PREFER_ASYNCHRONOUS,