Message ID | 20230705094655.44753-5-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 v5csp1755575vqx; Wed, 5 Jul 2023 03:06:11 -0700 (PDT) X-Google-Smtp-Source: APBJJlEtV9wQ+7YUpqgJeOKwuxj/y17oKIuSBTJCzcNXz2uyVkB097azHpwRYhN21sKw5k+AZOJb X-Received: by 2002:a81:61d5:0:b0:56f:e780:43 with SMTP id v204-20020a8161d5000000b0056fe7800043mr17730854ywb.9.1688551571206; Wed, 05 Jul 2023 03:06:11 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688551571; cv=pass; d=google.com; s=arc-20160816; b=XMhTc3gNXQVCLGveJEJdizB48sjd65x0lb2Y5S9yMtuBLtFctWUpDfT5fbrNS88fyD FDOEsi+5djC5seFvtWQ10Is2iIgz/Ivhf31DNKT0F6Ccwpm5iSKtthkdDwuK7YO3/JeY n/nf8T0RoXFarQWRLKfSUjDkUl2HThnEJiCc6u2wpOj2FPYkuXKTnW2xK5mHBZAG61HK ik/Jk/BHV6hkoDWZ182aDL9SiygB9wcp/uIXF6oJ4BOF3E7iq9M8FjTgepy4YiPw0y+7 6OLY1r37iUHnO9t21MHi7KVueiBKT4HpEFtQj+S87PSrdDQnkKLcajwvY6yX4Ct1OWJT zAAg== 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=MlZxzbmZ0KXhnVatLjdVj14GmndZ14kA93ta4Vhdcts=; fh=1holnKwvIHq9l/N4ifIzMuhZt0uEvGuqYJ6SHouv2HM=; b=cfI5CC1ZFlZJGBjLCJXIbKfs9OtTotBEs6SJvJaoPmBJhLtvJj56GjTcVtjqlkhlRD ON67PGW3YipgN8FD9AVbZzDCR6qPsnJDs2qKumnDxGjvkdOBOKycQwA+4dwiQNB0D//Q 4tlAHSXAWldqWcb4cfautgbUcoiYSoXNrc/kXFAlqrwSs4F6l3FrTpa8cZvs1i+uX4Jq Aezo/qvQqt4AOYEbUp40ML04QUEziOS5dwkAwBKve1tL1fcvP05g325ZNPzt65vJrJA8 gHtpyhHTuRjoxsOVkJazFBwlMtf4P9qZvrmEpQBLrhAL12wBWPMheNgjswOs9pIdAYxy QpZw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=HN0hLlmX; 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 198-20020a6300cf000000b0055acc7f8085si21257618pga.367.2023.07.05.03.05.53; Wed, 05 Jul 2023 03:06:11 -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=HN0hLlmX; 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 S231969AbjGEJr1 (ORCPT <rfc822;tebrre53rla2o@gmail.com> + 99 others); Wed, 5 Jul 2023 05:47:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58316 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231997AbjGEJrS (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 5 Jul 2023 05:47:18 -0400 Received: from APC01-PSA-obe.outbound.protection.outlook.com (mail-psaapc01on2108.outbound.protection.outlook.com [40.107.255.108]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8ECDB172D; Wed, 5 Jul 2023 02:47:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UwGR+3OroQbojeceLU/P5V1f7M09WxpWZlItNtVlZCIbib6hqnxzdUBqqRbhgiWr/M3Vt8s42aUySp4pmhNJOUSJxm0vrYmOheijv2dSPGXx7MlYC/PXNMGdo2zKqXrdnubcNiqR4hqeuMfuVFq0jg+KbYEd0K/QX4iqxgXhv6rMGQzl80svJxMYYD+IqfPWhYfWP3KubqtUbuOVN2jNmrDriQAeiKT9+7PnDTpQH4xeczCbv1wb3t6pCaifKZhFdLfPoJwFUPSRFrIn9CfO/xQBlDefZYrUR3mCpWT+iTY45Ao5w++Fccp0eP9vsgUvDDJgXBCUmiuMjJe7XDINIg== 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=MlZxzbmZ0KXhnVatLjdVj14GmndZ14kA93ta4Vhdcts=; b=i19/KnbTBXUIHTIr4YzUhtNAdDebL3pNvGHf7yVRsDNTN2dr8o+ztoePvY58c8jEdlQk7u9d0XxEkwYVB4CAD0WJ2Vcg+W1FLOtryt1gfroC8l1inlGDHTvGt8k7SQMhUgM6ZFvlSTlMN/5Sz0ALRgzSzBQ+0pC4YvFw/93RM46E+wdVvW4jMPvPcn/NjxB8mr5qyyZ1seTb6VbLwjYV+cM225J5NBjG44SAtT+REhyk3zFn1mUvP99MbY7SgaSm0o5WLZLAzVH76fA3oGdfqgsPQ8YBkarDAgUMRL0jpQ8OE5m+uFN+TmInxLnGJmOeNpWTFCc5hZXKlsMQUv39HQ== 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=MlZxzbmZ0KXhnVatLjdVj14GmndZ14kA93ta4Vhdcts=; b=HN0hLlmXzEXxbLG8WfM/lliJzKuyzo3DrSLlEQl3Gk4RyY5qHsGPOstlhfWBv5UJDYo6f9H+bee+AAYB1QPJ+9XBDVJcd7dAbih063OL4tv95s4+omWhL4GRsQuXfwCie0q6mkKn19xEmLUsWoIwm3c+UZ5NODPVEAcJXcap7KOIqWTpX72Lind2qGxXdJwYAH/LlfGVDhjZ5jZ6n/fM6a0flqEt9KpWfKz30aYA+8jjzg/qe0fAepgMdDvsmn/Vbw8FgkAlgxgl8MX1o0MuufuoShq4v6k52jmVar1EXQo7dVkwKt5+zsRZhggm7yNwSaq651t++D4yodpdS4aydA== 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 TYUPR06MB6219.apcprd06.prod.outlook.com (2603:1096:400:352::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6544.24; Wed, 5 Jul 2023 09:47:13 +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.016; Wed, 5 Jul 2023 09:47:13 +0000 From: Yangtao Li <frank.li@vivo.com> To: Moritz Fischer <mdf@kernel.org>, Wu Hao <hao.wu@intel.com>, Xu Yilun <yilun.xu@intel.com>, Tom Rix <trix@redhat.com>, Michal Simek <michal.simek@amd.com> Cc: Yangtao Li <frank.li@vivo.com>, linux-fpga@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 5/8] fpga: xilinx-pr-decoupler: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:52 +0800 Message-Id: <20230705094655.44753-5-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230705094655.44753-1-frank.li@vivo.com> References: <20230705094655.44753-1-frank.li@vivo.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SG2PR06CA0203.apcprd06.prod.outlook.com (2603:1096:4:1::35) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|TYUPR06MB6219:EE_ X-MS-Office365-Filtering-Correlation-Id: c2456431-d38d-478e-18a3-08db7d3ccf07 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 4s/RppLXxoHY3PN0K1xeViWlvgbKW/s4T4lf/ZVxwvBwPW4J7Af7zdgTCXGYxM/Jl+MStaOCD9lFE+IBHL79JRmYT4DHLdcxubiy/qc7ANgdIhtQAB2JTSmCH7tzX7JdNL2P2ItuW7z75TxLKcAH7cSgQP8FUv3kwwxTtfEOhnTvfbqrf6qb9DxNXNZQGrjbc4UbzcL6OQaHmLQQkUg7CNoYqw2K9U2LIPf6ExCnHtXsBSfl91cTHBHnft5sqo7Wwis9vYsvTbTDir4uSMOtD4miHmtBBWEf4uorRLbW0TxP2kEUiW5iSs3qYdaac6NNziszmQur1SdFE2t1w294BLsRpRrmaxILlQzaDEBieyrm1GR55817DoKkh5oPseq9dinfX0UimrCwk+T0Z3H9wK9ZtiGg9RaAdL0U37/efMq13HPizlGpxAhxkQp2aRz4cVWtXTyXZCbSOGoKQUmUDYsQEgLM0qR2PqOdg1dVPR2JY8LDepjQAszeSqh9n17EF2ZpdfYq/BC20fFiGFneBmpb5752ltCi+93/cPbg0p0/WHzbq1XxdOKN2uwbPxbFgtJ2P4Vpo32dYp2Tu8sX07jdYixGcW5RNqyA3fO26UL4MQklJmjNeIJRpDMGerMT 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)(366004)(346002)(376002)(396003)(136003)(39860400002)(451199021)(4326008)(316002)(86362001)(186003)(66556008)(66946007)(26005)(66476007)(6512007)(6506007)(1076003)(83380400001)(2616005)(2906002)(6486002)(38100700002)(6666004)(52116002)(38350700002)(5660300002)(478600001)(8676002)(110136005)(8936002)(41300700001)(36756003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 0H8BqldWk/jskUf7jRmYbB8TkRfi2w/2z6msPZ06QO4o++Ta3eCPjOsrJ6G4IidAN6KFjwtcnjHDrmtuSLohh09Bvwm2aHmnswfLeSX38aa4AbMMTU9CgyA4iGqLUDf1UbAch/IiWIsLhtgLOGa3SztS6i7g7E6HLrs/UoZ6+nP3+FDNpJcf4F+oKXgN/bptU5b9bOkkpr2cUgCA3pUWOrQvjUy0/3cVkIUXe22MMKGL5lfk3sO38kZlFBzZRQWEkVAWdxxL4eWhFl+ZCpIsdUFHJjlU6h8APmTpGr/ji+kYIDnMcfPrEpqCeL/YPeAnbxrjtexIdj1ntC3CJ9EZhe64X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crtaq24GmgZEoUiE3DKHbrbsU5DNLkdHdi49+gsMbWz2wSJLy6dnUTAnBxAbM7L5YFDzSMpnxqZ0Rhosg1OdBH/J0sMTJHwTD7SVl1UUqU8ou0FVY+tAfjwutMNvfII0yZu+dz/E2NrNPZWBlsUvMrar4ipY6X07CJlSx83HHXS X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: c2456431-d38d-478e-18a3-08db7d3ccf07 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jul 2023 09:47:13.0223 (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: jFNH8VLQizfzM2X4T+Lr5A0qeVzGKF6GCaNUKBZDJsmQq0+q4g8u4GnQo9jKfZ0wKLuXmW5KFfcfpJGFIR8D+g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYUPR06MB6219 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: <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?1770574652285470266?= X-GMAIL-MSGID: =?utf-8?q?1770574652285470266?= |
Series |
[1/8] fpga: bridge: Convert to devm_platform_ioremap_resource()
|
|
Commit Message
李扬韬
July 5, 2023, 9:46 a.m. UTC
Use devm_platform_ioremap_resource() to simplify code.
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
drivers/fpga/xilinx-pr-decoupler.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
Comments
On 7/5/23 11:46, Yangtao Li wrote: > Use devm_platform_ioremap_resource() to simplify code. > > Signed-off-by: Yangtao Li <frank.li@vivo.com> > --- > drivers/fpga/xilinx-pr-decoupler.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/drivers/fpga/xilinx-pr-decoupler.c b/drivers/fpga/xilinx-pr-decoupler.c > index b76d85449b8f..208d9560f56d 100644 > --- a/drivers/fpga/xilinx-pr-decoupler.c > +++ b/drivers/fpga/xilinx-pr-decoupler.c > @@ -108,7 +108,6 @@ static int xlnx_pr_decoupler_probe(struct platform_device *pdev) > struct xlnx_pr_decoupler_data *priv; > struct fpga_bridge *br; > int err; > - struct resource *res; > > priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL); > if (!priv) > @@ -122,8 +121,7 @@ static int xlnx_pr_decoupler_probe(struct platform_device *pdev) > priv->ipconfig = match->data; > } > > - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); > - priv->io_base = devm_ioremap_resource(&pdev->dev, res); > + priv->io_base = devm_platform_ioremap_resource(pdev, 0); > if (IS_ERR(priv->io_base)) > return PTR_ERR(priv->io_base); > Acked-by: Michal Simek <michal.simek@amd.com> M
On 2023-07-07 at 06:55:33 +0200, Michal Simek wrote: > > > On 7/5/23 11:46, Yangtao Li wrote: > > Use devm_platform_ioremap_resource() to simplify code. > > > > Signed-off-by: Yangtao Li <frank.li@vivo.com> > > --- > > drivers/fpga/xilinx-pr-decoupler.c | 4 +--- > > 1 file changed, 1 insertion(+), 3 deletions(-) > > > > diff --git a/drivers/fpga/xilinx-pr-decoupler.c b/drivers/fpga/xilinx-pr-decoupler.c > > index b76d85449b8f..208d9560f56d 100644 > > --- a/drivers/fpga/xilinx-pr-decoupler.c > > +++ b/drivers/fpga/xilinx-pr-decoupler.c > > @@ -108,7 +108,6 @@ static int xlnx_pr_decoupler_probe(struct platform_device *pdev) > > struct xlnx_pr_decoupler_data *priv; > > struct fpga_bridge *br; > > int err; > > - struct resource *res; > > priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL); > > if (!priv) > > @@ -122,8 +121,7 @@ static int xlnx_pr_decoupler_probe(struct platform_device *pdev) > > priv->ipconfig = match->data; > > } > > - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); > > - priv->io_base = devm_ioremap_resource(&pdev->dev, res); > > + priv->io_base = devm_platform_ioremap_resource(pdev, 0); > > if (IS_ERR(priv->io_base)) > > return PTR_ERR(priv->io_base); > > Acked-by: Michal Simek <michal.simek@amd.com> Acked-by: Xu Yilun <yilun.xu@intel.com> Applied. > > M
diff --git a/drivers/fpga/xilinx-pr-decoupler.c b/drivers/fpga/xilinx-pr-decoupler.c index b76d85449b8f..208d9560f56d 100644 --- a/drivers/fpga/xilinx-pr-decoupler.c +++ b/drivers/fpga/xilinx-pr-decoupler.c @@ -108,7 +108,6 @@ static int xlnx_pr_decoupler_probe(struct platform_device *pdev) struct xlnx_pr_decoupler_data *priv; struct fpga_bridge *br; int err; - struct resource *res; priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL); if (!priv) @@ -122,8 +121,7 @@ static int xlnx_pr_decoupler_probe(struct platform_device *pdev) priv->ipconfig = match->data; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->io_base = devm_ioremap_resource(&pdev->dev, res); + priv->io_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->io_base)) return PTR_ERR(priv->io_base);