Message ID | 20230704131939.22562-2-frank.li@vivo.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1229335vqx; Tue, 4 Jul 2023 06:39:08 -0700 (PDT) X-Google-Smtp-Source: APBJJlFHeN247hKdyrNsoczBoh+xv3qSYoGI2p2lC7WQRcTvRKvnzXB0aedgKH7gXwmcXNf+2oEb X-Received: by 2002:a05:6a00:23d4:b0:668:7494:384a with SMTP id g20-20020a056a0023d400b006687494384amr18707325pfc.12.1688477947947; Tue, 04 Jul 2023 06:39:07 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688477947; cv=pass; d=google.com; s=arc-20160816; b=flyXkAZYgwZUeTfpURY33G6O0oxNrytjGajBPH/L8YP6oCknvpTYTND1vUc3nclvqd WJITagqoAYx3wZoN+zmH+Tb2p1jo4HcHxiXcL1su/ptUF6eeWRU7QGYQrZKB/GLKgTOw HNxhh9fTHVtO71/RS8ch0ojFWm94bA6edBjK65f3OvXTMsgva52G++szP4v3ECdq6bTf 9SXT/5ccFaM3JJ/yh4pqN+copLq60n1fzWIuiffhzPR1fxC0sFXNylzZF8V1f8WfMMx3 IfDoYN8ng8p7odspAWWRTtTqXNGI50JogCB7mMMBCFqxysnOIRd3yDgfaGDItjTutF95 oigQ== 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=6BLyFlcu+9o8COCZQ1tv5oRD+VsOX+UdYmPcWTunpMo=; fh=76qAH0Vfz7eME4nZA+TW8iUmULHJ97R4o7wesGShICQ=; b=xlLHQ4aH1pk10lA2vGhdV8kJSJXeGNPW4UcQuW9YAZx7U9AdnqbB8vvsb8vs2HxW+3 ZRrDE1QTznsoQRcZCPat0fXF8vzAi6GLHL6m94KBEOnicXVUI66dRZFzpL+2zkpuQRmd S2E2yzpXnj1gh01HiRkoCjoMohcVfeBHuy1zHkkvr3NhYIjcdqTZvUmr0n6vJP3FzQG6 cyjI+vvLQXBlYnLgIChni+XOWWUAjIKV8H3sH2kc2DLxHVB772EL7CXRPhC5p0Z0NtBy FCYDBGVW+SwAhbEV4G4k92T1UK+sPRnmN1oH0XAiaupOlO2NOvtyPRVxbvF0axdO00ib Arkg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=F8R6qyX8; 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 r7-20020aa79887000000b0068259969675si9686691pfl.297.2023.07.04.06.38.53; Tue, 04 Jul 2023 06:39:07 -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=F8R6qyX8; 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 S231408AbjGDNUx (ORCPT <rfc822;tebrre53rla2o@gmail.com> + 99 others); Tue, 4 Jul 2023 09:20:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41326 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231443AbjGDNUV (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 4 Jul 2023 09:20:21 -0400 Received: from APC01-PSA-obe.outbound.protection.outlook.com (mail-psaapc01on2114.outbound.protection.outlook.com [40.107.255.114]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5B34310F5; Tue, 4 Jul 2023 06:20:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=A4686rG0kmNEiUv6oM/kcbqnacLPgJ49jUnWhxtMX3xQ40TtVHrysSHQzaaffbWaKZhmUR9qjAkDGFHKosPMb2J8IlL+XWfaYzwjLIm18mZGcxd/EftpzKRGgNKp2SULbCyl74K/ABpkckFrEYiAgnSUe3dbWu8dNA77I432EcYsOQXZZXFAFH3BgF/eR8+BTkT6NzWcqVFvzXFP6zX3ZjI9oadKExFtHUOH8mej5satMGkBQapPevVZKLE6pXA3VDeaBrHu7y2TKDUdRRqEK7jTvpHS3UXkWPBFSb3O88NbqRjDq3paZUj3w9O74NNegT6mbc/ublIhzpxaZlZ34g== 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=6BLyFlcu+9o8COCZQ1tv5oRD+VsOX+UdYmPcWTunpMo=; b=Tn2SQsAOAkLZF6y/AklYhs7vYSLa2PVyvbiqpDsfeYMuviqD6uUA2FF8zAUCajFF8pY4sJx8sjBVXT7G9v8sR7SOMo8VzyvhPTimfSoss+izDnRs93wKovEVbWARny0GY+ckSwUycPNCbl3xewgQdaryFJyaElCtWuR91euFHVk3HSW5ABuU/ciHW1g16NRBc7I3LtV1RgnJwA/bmj9DMKL894qfmo+oKBoHLBQwOoB4UUixMDv6N30AactmsNQZLywh9KmsOFdnwHx5vVAk14GoQ5UL8+kbypAfvdaqqtFbl6TWYC2ssQKnr+yfI72CATRGYKN+PLNa6LnWsB3vjw== 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=6BLyFlcu+9o8COCZQ1tv5oRD+VsOX+UdYmPcWTunpMo=; b=F8R6qyX8F/n2DuesV+1Slamqpadu9/vhw4iM2SM7qSCwDiTUzSK8d1dF2idPvZrDpnq055ETJg+1x+T/wW2lG2xCwt0Lx9SThfZ0pyKC9ZKi6D4nYERnEvZ3+W9GIkLbRJCxI8WWfJKouCeUYMvnoQhE8ik3DS9ULzkG3ZJ/KVav+iifqE7S+MyzqTgIz6QT6+Bf9FXOngDdhp0C6TB7NhKQFKGZxehwx7GM1xtZ1PH5ynO71Hh5PEAXoVtL7o0r4JTmdw2cti/uuBb4LBVt/3JX5keXqPJwBM9B8GPsp/HV4CccgMxQ4++MuZ88HzDJ8PC/Ihwv3PGXEibWEzzbsg== 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 TYZPR06MB5027.apcprd06.prod.outlook.com (2603:1096:400:1c9::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6544.24; Tue, 4 Jul 2023 13:19:49 +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.6544.024; Tue, 4 Jul 2023 13:19:49 +0000 From: Yangtao Li <frank.li@vivo.com> To: Ulf Hansson <ulf.hansson@linaro.org> Cc: Yangtao Li <frank.li@vivo.com>, linux-mmc@vger.kernel.org, linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/3] mmc: omap_hsmmc: Use devm_platform_get_and_ioremap_resource() Date: Tue, 4 Jul 2023 21:19:37 +0800 Message-Id: <20230704131939.22562-2-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230704131939.22562-1-frank.li@vivo.com> References: <20230704131939.22562-1-frank.li@vivo.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SI1PR02CA0035.apcprd02.prod.outlook.com (2603:1096:4:1f6::8) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|TYZPR06MB5027:EE_ X-MS-Office365-Filtering-Correlation-Id: e1152ddc-3963-4f38-6ab9-08db7c9157e2 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: J0IfAwsRRaV1txh4en0Ac3V/lW5XXPPBzrnPPAfMjn+cVME3m+tqgyP9lr2nUVa/ygDTNeyttLV0fh2Z2KSJ8osenMeOvfgCXg9nxCAp+7W5+jz6OeANHJbaUzMDH4jnlTC8aigaRlFwPz7qoTz6255GSuGkRuLZpoqyZ/ZFY+P1j+ZjO9fxya/u6eheHOXtPzxQCTZvZERTor7luAKt/mK/ZZv3h2eUEpry45kTwUN3fI2OFrWKEQaCHr7VeUGTe4r8qKIGoiEX++1ngUSg682cKOw/anT1BCVzA+e3HRAPD1tRThk+EmBcy/b2nsBvsHtUio44wXaT0YLSIts6pm0IEnntonpBwNiUw3FL9DiATZRiaAUG9HNJQQrSaol6NDq0/7PsFixBsDlwV9Z5vP2ApmHY9lKTKuDva4kg8t7RVLxSkiz762i7sG99287M1uiODFLq9kVjRuEbu7hKNknb1f38nm4bkiE/3XSPG9U2zc1VRoMHSvItpIaGj4LjypReCwWQvgvEymWIDPaEsYxm0wRAmOX2cQwuwPHDBdGh4SIUnYpYnM7ZsSwbMGVxQgRx0hnTahdDPPT7ZnfN3BwT7aDaWSSBqO6KWPT59JCcY+vOOt1UUbGWThnsGXLA 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)(366004)(396003)(346002)(136003)(39850400004)(451199021)(2906002)(4744005)(478600001)(26005)(41300700001)(6666004)(6486002)(86362001)(36756003)(52116002)(8936002)(8676002)(5660300002)(316002)(6512007)(66556008)(66476007)(66946007)(4326008)(38100700002)(6916009)(38350700002)(6506007)(1076003)(2616005)(186003)(83380400001);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Npw/c2F2Nkonpu0GdrXH0+wwAa9rIrbPBPrINVrcw9mrFV7y8+8ONkbMsh2uLS7bk66d4m3B144YMOgBWY9bLEkPV4Ds718PmvAET/CanVkSeA5SNlEF/d/1K4FPP3MZPQK5aRAfIW/hVK/NWTktB0jksrfDZBfaSloga5p0qbiwNgm0CA7ug3baVxIaPWbFozG9Z8m6OxWtNZwz+7YML2ohD0w7ihQhKiv5o4D2NJAtsgw4/hPWjE+Eou/nZchGIAIa453NT/IzAcOWA6zOI5y3vFWWx7VwQXpyEj+TG9Fx7j04sYeF6vjXgTfpz4ggIzatW+b9KW8zMmaJfAaVMijbzaD1VvLObRw7ZZimNY+EyZYNsqHQZPTy1EuIvo/fVBDLgdwcGBZitwFSxzBIkD6sbkvJ6kkxVdXl0hfMlB27c2Un62xpwsVfWXQv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sbKZVVhVlnKEwhoDV91Vz5tnZkX4XXsulFnbuwvczSEwViI7ZUkK0I4sQD4BvzJEvB5ep X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: e1152ddc-3963-4f38-6ab9-08db7c9157e2 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Jul 2023 13:19:49.1886 (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: ZzRYVE8zSLBnGxO8pxyZcb+wYUUOh9CFBdQcjwLZP+BmF0O6OwAEu7egfCypcn6ckjMspEYT91c+8AJGjgJ7yQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYZPR06MB5027 X-Spam-Status: No, score=-0.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,RCVD_IN_VALIDITY_RPBL,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=no 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: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770497452759892114?= X-GMAIL-MSGID: =?utf-8?q?1770497452759892114?= |
Series |
[1/3] mmc: mxcmmc: Use devm_platform_get_and_ioremap_resource()
|
|
Commit Message
李扬韬
July 4, 2023, 1:19 p.m. UTC
Convert platform_get_resource(), devm_ioremap_resource() to a single
call to devm_platform_get_and_ioremap_resource(), as this is exactly
what this function does.
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
drivers/mmc/host/omap_hsmmc.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
Comments
On Tue, 4 Jul 2023 at 15:19, Yangtao Li <frank.li@vivo.com> wrote: > > Convert platform_get_resource(), devm_ioremap_resource() to a single > call to devm_platform_get_and_ioremap_resource(), as this is exactly > what this function does. > > Signed-off-by: Yangtao Li <frank.li@vivo.com> Applied for next, thanks! Kind regards Uffe > --- > drivers/mmc/host/omap_hsmmc.c | 5 +---- > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c > index 1e0f2d7774bd..93de00a06aba 100644 > --- a/drivers/mmc/host/omap_hsmmc.c > +++ b/drivers/mmc/host/omap_hsmmc.c > @@ -1790,14 +1790,11 @@ static int omap_hsmmc_probe(struct platform_device *pdev) > return -ENXIO; > } > > - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); > - if (!res) > - return -ENXIO; > irq = platform_get_irq(pdev, 0); > if (irq < 0) > return irq; > > - base = devm_ioremap_resource(&pdev->dev, res); > + base = devm_platform_get_and_ioremap_resource(pdev, 0, &res); > if (IS_ERR(base)) > return PTR_ERR(base); > > -- > 2.39.0 >
diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index 1e0f2d7774bd..93de00a06aba 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c @@ -1790,14 +1790,11 @@ static int omap_hsmmc_probe(struct platform_device *pdev) return -ENXIO; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (!res) - return -ENXIO; irq = platform_get_irq(pdev, 0); if (irq < 0) return irq; - base = devm_ioremap_resource(&pdev->dev, res); + base = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(base)) return PTR_ERR(base);