Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp556837rwb; Tue, 25 Jul 2023 21:48:17 -0700 (PDT) X-Google-Smtp-Source: APBJJlEcXVW0M20BlxFva+PSS22IYg4+KuDOwd/KsL3oPZy/5Alf4Frx8U3+hZK3xvS7Tg3ZWaIx X-Received: by 2002:a05:6402:5179:b0:522:29ec:3e0a with SMTP id d25-20020a056402517900b0052229ec3e0amr623502ede.28.1690346896975; Tue, 25 Jul 2023 21:48:16 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1690346896; cv=pass; d=google.com; s=arc-20160816; b=fp+yLLhOfMHBkvQ2JD8+VwvGazS18FX6RQeGfpcetEMTdCw9lfg5GUfk+rAHi7ql6D odIfK//elmSW0ZoZSYQGMbhunyv0vCbXxW81bc925TgcEBsUqnUvPgjxy2r0rPaBVyFE 7R9Wje+SbUGEFHeJfZXLy9EyK7pR4mNAr2W+cjwYc5S7SfadjKv1nnqb6Z4CzVcQ0tp4 4SMM77V3eltzPqKZu4Mz9MTaF88wqRLSJVHOFvAl/XzRumcrepbqktG7XgktULZ5Mt6U +allyIqv0Kjtq4G+ZKRnSnZD7NcHIf6NrJazIX1HacS8W5/2EnOXS8QgiM5Y5hEAF8MO YyBA== 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=cO/T/iqSahPS1fYBVSCrfdexxtG7yArNkbxS9PglIXI=; fh=E03QyiWENBCRDAuP5hv9oopN2sdsL+hYvdCq53xM60g=; b=bt/Fq+J0osUEcbEz+SfEjByz3rz48dgRRcWgS96/16gXYxvz+hsmH7FrJd8eIpCzyd +tWVvf0VhA+VAIo8z8A0GUuFgawyhkmedfZX9FQPBleM+ma4P1/BPvMks3yM8k8vSn8k ljRD8EsFR0fFcwy0jvaf4pK2gy3UPJQjiHo2ksD7TC7GVSMbevEmxNaxp2nTkhbAa3jd hbGfIFk/O3OCN/bvwus9hYFdJYYNiGHe6oTYv9/zenFZ2oLMVT+rZ4LGHlfh2pIo+OJv eCIRrmUpubNSFTlVMJKPErKs89Nz6n3ggllC/h/A31c9T0Pdw9KlAD8G0/4HgO2JBhsX RnxA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=QhMbmKRD; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c7-20020aa7d607000000b005222709bc35si5045625edr.197.2023.07.25.21.47.52; Tue, 25 Jul 2023 21:48:16 -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=QhMbmKRD; 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 S231391AbjGZEBk (ORCPT + 99 others); Wed, 26 Jul 2023 00:01:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54440 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229659AbjGZEBN (ORCPT ); Wed, 26 Jul 2023 00:01:13 -0400 Received: from APC01-SG2-obe.outbound.protection.outlook.com (mail-sgaapc01on2131.outbound.protection.outlook.com [40.107.215.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B799C26AE; Tue, 25 Jul 2023 21:01:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Q6Fj2eaCRx8IYRQ1S2pTdSEL5ARbT8T1qV6G9GIOxcxQZ1AVN3bFvaJM+8ykxobvEMor/GThm0vaiJaTL3ziXTNuv+TfPt48P690gqdFnASRotCTfIjUwplw4RNG89TeEPAZyT+Ep39TYGLWMulXFA1oLv25vGZl1Sqzfk2MVqR/u4zBoUM31BxVXaR7uS1RkVYPwKLULdkSdv/mquxlmtxJj3UPUsj/L6c4SqIPoKIPqg0+ed+UaE61BM4GC8b469ipG1k5xe7GVVMTcz6W2ZjCvYnFE9lp90SxWqip2ZbYvt2sOCxskfVIZw0W3B9xk8MM9+5kaVH8o1KbdsorMA== 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=cO/T/iqSahPS1fYBVSCrfdexxtG7yArNkbxS9PglIXI=; b=Fd9oFGRnnzLi+AlbLo8y1jFKTXmyoDmbwne7NVmEz3v6sybuCYSUw+StAXyHlB4gS87NDL7QCIPiKQ0H6RmmIDDeo6xbpi3LBLhixwpkRsTf+h2DCGgX7YTo0r+m7g3qnVRu7ZBeD3O790fRjtWfXZ4qNXkRj6d0mJKcayCJ1+fp6pb5wg+/sTkvg1VBI8/PWM1p2TKQL7UfFxMWZLwAW4k/p0BCUQ0jVE7M1hUZ30ARObhz48FhpNzzM8lUk4drohzLw4EeWMnVr2GU1JS/f3eWbUwdAy0NMtgIjinzSgzrLXYEiZM1TT8u6NjU0lfNgcCZJyiUoosuHKpDzGhHRA== 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=cO/T/iqSahPS1fYBVSCrfdexxtG7yArNkbxS9PglIXI=; b=QhMbmKRDdXg/OOQl6guPZoP+oZy9Zw7wimdcwfz21ME/zvYegLzLrQhJNP6GJzaZ7rleJE+mFuv6MCJxLHKP6Y7WWrZ5L5lBburryLpFkYtuU6H+V3M8PDYO0FsCi2LEAmNuJ+oh1IudwNcPhSLhltIRN22J14ZJpudo1M5I82BK/YNokH0x/LjvltoDdjuEiSzt/AAKrBM9SaUNoDa4jg20N0xfdthwrBwtXDhZKh3+fgJqk/tVTZhjrvofKOXa5I/zRc1wptjMt+M97pKLJ8xsXOXLWMy0msojDyS1j0XVe2on5F+0ykUynkkJPkYJO0o+M5ihzVtXTI2kEM287Q== 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 KL1PR0601MB5463.apcprd06.prod.outlook.com (2603:1096:820:c3::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6631.25; Wed, 26 Jul 2023 04:01:07 +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:07 +0000 From: Yangtao Li To: =?UTF-8?q?Micha=C5=82=20Miros=C5=82aw?= , Ulf Hansson Cc: Yangtao Li , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 06/61] mmc: cb710: Convert to platform remove callback returning void Date: Wed, 26 Jul 2023 11:59:46 +0800 Message-Id: <20230726040041.26267-6-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> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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_|KL1PR0601MB5463:EE_ X-MS-Office365-Filtering-Correlation-Id: e7f4c318-dcda-4de4-0f5f-08db8d8cf09d X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: wLQCY1k12dIcrpD6mDGr2zwjvt7VUyMsPucb03BhjehQmdPbveh5ZKpCqCOwK45KjPkYtOTNL62MJHnFoMS/6Gxhbft4YlxR+KUtLtG0YRBgJhMQdm4TiU+vNR1sAY5bVN4GhfxDkU7iqQ1eX6aH5hz1qaysLCtxcgCcEmPfZpMCJXLofLsclJunctrEVkMU7Bbdd46C/tm0vnwwYEBKpMe30BCchBcSJpmt2lBghH5MVwaJ8GlaNq0ZBfHloHydOGBcLJ6pNLM/cmdod990TieIXHYTMVs8MA9hPQtdfi/c4sLHniDSquqIraTkQ/zYH0bm0GVfc0aCm0DHEi/9/OgUSJ5CRd742k2X9necMSEInaqypfGD03PKVy4aq4YgHQQehgTX7nOsxu6soj3GuTCLlv3Mo+IQ9cJnewiRvRbrIynvg2uUxytI1orKvjvbFVnj+wr7SNJpRPHH8l9Bi2i5zZhSS2verJh9YtgR0CXh7pu40vXUZUWwc1MbWd25mzDA58aZUHHPhIv6QpnplQjaBcN0q9FuZfs1YQHQUD6jMURD4/Mzdtcq2P4Fj9gMU75ujF+2oeys3DlCeIfZ+W1bOaU1yO2xxNh6l0cVUtM74Ndv5vrlbzRg8yNFMuzs 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)(39860400002)(346002)(366004)(376002)(136003)(451199021)(110136005)(54906003)(38350700002)(6512007)(38100700002)(52116002)(6486002)(6666004)(478600001)(41300700001)(5660300002)(2616005)(8936002)(8676002)(66556008)(4326008)(66476007)(66946007)(316002)(186003)(83380400001)(66574015)(6506007)(26005)(1076003)(86362001)(2906002)(36756003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?azlLakFkYkwvQWhHZ2NpelVwU1BVd05OY3E2SzE2dlIvQ3J3VCtaNnJkYitn?= =?utf-8?B?N2xVUStJMkUyK2Vhc1ZwRHNwTHFBV01SMUFQNHl0TzlIbnVBVVNLV2FnY0J3?= =?utf-8?B?MURCTHNVLzQ4Z3h4TmxYaVBtQ3c2cWlrRGFSdmo1VnQyWUF3cWMrWllzd1NR?= =?utf-8?B?U0lSelZ3aFhBWnAxRlhmMUFFTTh4WDBXUzh0bVVTT25Eb3FiSFVLMC9oWXg0?= =?utf-8?B?WkVXazBWbkxRelg3UDUva1piSXRINE5xVG4xTzQvcmZwcUF0WTlSRnlZTzFF?= =?utf-8?B?QW0rVmczUm0zYzZyV3dQN0hIdGNUUTU3aWkydmp4MlI1cHlTQXFlU2xPMW1H?= =?utf-8?B?dkJjZHFsQTlEdldGeGREbnlqZzFXMmw2VkVJNmpKU0VJbm9ZTndna1MwRTE0?= =?utf-8?B?Rk02a2N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uthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Jul 2023 04:01:07.5966 (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: XUcIEx4xz10cX0FJjvBbUcd0h+GklEfN9Pqbhpnxak2irWl4W/01ec+sgjNeUdCo3fsubaw3Jsh2YZlmcbyhOA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB5463 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 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 Acked-by: Michał Mirosław --- drivers/mmc/host/cb710-mmc.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/mmc/host/cb710-mmc.c b/drivers/mmc/host/cb710-mmc.c index 6d623b2681c3..0aec33b88bef 100644 --- a/drivers/mmc/host/cb710-mmc.c +++ b/drivers/mmc/host/cb710-mmc.c @@ -745,7 +745,7 @@ static int cb710_mmc_init(struct platform_device *pdev) return err; } -static int cb710_mmc_exit(struct platform_device *pdev) +static void cb710_mmc_exit(struct platform_device *pdev) { struct cb710_slot *slot = cb710_pdev_to_slot(pdev); struct mmc_host *mmc = cb710_slot_to_mmc(slot); @@ -766,13 +766,12 @@ static int cb710_mmc_exit(struct platform_device *pdev) tasklet_kill(&reader->finish_req_tasklet); mmc_free_host(mmc); - return 0; } static struct platform_driver cb710_mmc_driver = { .driver.name = "cb710-mmc", .probe = cb710_mmc_init, - .remove = cb710_mmc_exit, + .remove_new = cb710_mmc_exit, #ifdef CONFIG_PM .suspend = cb710_mmc_suspend, .resume = cb710_mmc_resume, -- 2.39.0