From patchwork Wed Jul 5 09:46:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116047 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1755317vqx; Wed, 5 Jul 2023 03:05:44 -0700 (PDT) X-Google-Smtp-Source: APBJJlE4Ztpkh13L6FAQSMlkfi3qSd+dTUjPDWgzYMpzrLmt/Eoda0EZwrqKanX8VMYsmBiG44Q6 X-Received: by 2002:a17:902:d902:b0:1b8:5b13:5958 with SMTP id c2-20020a170902d90200b001b85b135958mr11446055plz.31.1688551544168; Wed, 05 Jul 2023 03:05:44 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688551544; cv=pass; d=google.com; s=arc-20160816; b=uqX+UbztPYUARm01awEtZx921nJYqiRYXQlYrf5A3IBL/5RuwoIYJJwMqcSRy+vAns N4dZ1BXW3qlCAkLsYkq5D/RsK8HLaTzgD3psprVjcwf2tL4k4vi6yTR60hRPU39mGGIX QHeWrzx4bJRCo5haPaVRz0yJHj+FQXAhguzkaN4WuXPfZVrugnvxMHEu1saShctSp0Lj RL4Q7AgXvwJS6/w+ceiQp/WAE+9ZMmrJBLOj//v5lNZfK9x8t3PEv/jknNZR7ustpHHP TVDwZqWOUinOOYmmMZNCp3AOhWo5VL9pK46o4o2AN0dwERG7kVNR72s2SlVNyc87VFI8 o0iA== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=6RVLV+DRWVTxkFRKiZWy5JIZiY0q+aMhKaE7SR+5njA=; fh=FeT5G38czCxbFra8wh3CNM+BAh9ogjZ+EeOzujh3CE8=; b=YuCPv059mcDY73bvGf4/w20/kbdFFWtP/hZgB1BuV7kZzxWU+5xX9bTDxKLP2rF+y/ QN9GaNk7mdKUpdW14/4PN57RDPWHtN0bkxJc5oswXADrPc3sf3qr6tQrNvS6TMn0BQS1 10NPsJjmPqffF6MGXHHbL4z2ZEjeMH/14z+GtatO/K1CUWI5Ndx1rnFCb3yKsyuwdFfk p0e5MVvcJZjN39e7m/CMDbEqLrb9ZkcMIWFm6AL4xV8cQ108XK81NT8aIdp3Ms+x1Y2I n28CS0GkFW2i93iyV/tP95+miXiwbIqSXuMDkCRewAl0itkkVyHLg6wTeetbibnyhUH4 LK4A== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b="cFE/lZyE"; 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 t2-20020a170902e84200b001b89b7f68b2si6272554plg.42.2023.07.05.03.05.31; Wed, 05 Jul 2023 03:05:44 -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="cFE/lZyE"; 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 S231956AbjGEJrN (ORCPT + 99 others); Wed, 5 Jul 2023 05:47:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58176 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231784AbjGEJrK (ORCPT ); Wed, 5 Jul 2023 05:47:10 -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 8AE15172D; Wed, 5 Jul 2023 02:47:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PyFqWKWBUTHZb6uvv/QgVIkBy47tI4BdqbU3FVzkjSfr3a/jq3dXXMOSW5E/7LSGMY6YU/BfKe9g3Cda5sBvgXj/2DTkq0cdEjaCOsL0kF2/Lv4HNAhWd5LPhMoMg6OvD5zqY6Gkzj0a1E7xmfKuiepXpz+0J5H1/lLA7cvOfLH7hOcjxe5ciKJTnHFNINjpEBzRFX88xkLY4Drg8A3n/zHsuHrjSaR0Egq/RN8i/MkpXAwBBlR5NtzHrwGVvr//8v42oc3NJKW8oMFmidF0zfVcVrWwOslZalsm7tGoio+2dUXyh7akY7AP21EuEXOxu/WUlIFYjqExvbCHfRszvg== 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=6RVLV+DRWVTxkFRKiZWy5JIZiY0q+aMhKaE7SR+5njA=; b=G1ajSX/CxfQ17Hs7yGlLrvE+rtfz9rxv44V03k44mBfLlCqNaPEK+dovCMHlNeP1nfYKbwomT5vXtXD1mPy3LNLlkTlqyEe7GSJVXeUsdwHjTEJnEUCM9hEJO9VNbhsBZUwlCgAk1Lrs7+SP7I7uIe9ayhdVzpEIJ77Y7VaYHvG9yqCccB2g9czzxaLwq5eGjlxUUXwwTwpjla4i+5MLIu3lJLrWEbkWDdi5otJgP8M3MRH2b7RBLDAgVMwugubILtPP0YyxxOKATQnVmrRvPO2gFqAJiYe6JbBG9RnXm7CcQNmcePrF+N0Js7zm0OG8qI+/MgyV2JrP4ut4p6WIoA== 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=6RVLV+DRWVTxkFRKiZWy5JIZiY0q+aMhKaE7SR+5njA=; b=cFE/lZyEiKLNqPolnMX+OCRrHOA/xOGfDnd1OMbb8VWWAQIYGzM5PY+CICUeb3iQdROSh8jBmfF47EIfrCocNZyDuoan1siFNyF3hTLHhZtOxXvCEq/ly+5jf3b1jVNcL7/IsPsW3lggyA6z1Tk72+kUh1SMjVdowqcM8KmV/wRNaIE28mpFcZLHZ1AOwHT+qpr4iOtaEJeT9TCfnNk+QScsnT8bnJcPP9mezARvrvPhfuzhGgrLpgrJTrE/A9WIT5WaTV6yZjURA1xLyZpYVdjJARYo0mqtE3EWYH/NSP7pi6RHEuBaVUmRmqbRK1dgxsHCYr4/iuIbbR7QLKa33Q== 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:05 +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:05 +0000 From: Yangtao Li To: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix Cc: Yangtao Li , linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/8] fpga: bridge: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:48 +0800 Message-Id: <20230705094655.44753-1-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 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: f350f6e7-84a5-41e1-8fcf-08db7d3cca10 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: j4xpYkl9i7B23iMudcvfUnRDbIryR5Nk3WQ0dNfH5heEPOrB5J9xlZfdwURN8JUNHPhElRtRJTw35ALrm/pIYAKsp5KqAcXcOIs9B6+JbjsaqeefG9l3nWnEB/5OA8R4EaaowkOSDPxhhsl3XspMUmDLq4dAYCjOamecET9GeIxhjZ9BPk+UExEn7k14UQVpg/0U57ccUpmvvvE3qA/V2x8fw+ahWbuf01bpccyhQ5UeGEnCr1AGhpwxz3qWyvEvl4ECDY2Uhs1weGf0k8Jf1YeSoLmiKVhstj83uV1TGst6+aoMXbnrtVhai9ryq0OomQWeAX4z6nM+pLYi1PW49hZ0fobnEM3zjcpMdjQfqm6aptJ4uBeLf9vVSDPuB3u3NCCjUdzegxGubuuqHGGfjw0hwmV3uTdjzE6nb/6Zzi+vFmRMsJtTnJGbdAoUqFuOGFeSudg1ardAgkQsP1AcjfAuxdw/A9HC4Kc1sFPNJSis5QKBNdr9hwi0m2bkHLCzCh+xtJEdYbyIjgRcKrTEKjipetWDXki3UGbGOV1nujlXxyBX0B1hju1ngYwRE+zZh+ulpQUqCLU0g8SgPEAmZjjNm3RBgHnd0vY8tROzWLkZ0+wc79GK81rhi8ws8AIa 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)(4744005)(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: fZJBgfJjvk25d+LXDZM2wxbbj8d92qbT4WRjtm+ftZhCQrBHFFoTn99uEyyXMOCZ/n3dfu/leca+Thao04lkzJ5EzUvRNO3oi3ZWbLjEfXXYcsIfR06+59S59F+AKr2cl9v4ZLQ6Ay5LH3YdHUhh+lei9KucPYYADb5OoQDMyudo4HYN0HKUI6srR9LZUkFnPOkfKmzYZHVHeuE1NH43upSd/7MI54KnbhA5ZASq7I5i5Z/d2YC3RCxYMyRIJQqkDytzP/K0vo1EPH3EKnrwz4e0p+y9rPHHx8E/6rQlysXjGQmhkFTI3OF+ZsBQTiuJwpMQYslgugKVtIpILGr3VAffGvmwAs4yDNzmb7FNLdrstRpSmUYixMLXEvngTI/EW7+gg3oiPjSEjIbKi2fVttcHSDGK7qP5NSQV9A/zIuQiymp3TX3R/VmciIczikIRLe38MktjswYwzbbCdJ43z264YEngKBgyb5VQAeWPLnFBY4aIhosQHyAwZHygL6cytFJ4ohOZ4QAHqOB4EZf8gR4zDdKkI6u1MhTU8KR9dwyWs9MprztrAAY+E+OFK+gIeAZhE0ad9fvp4n5dj36GtNwCF5PbUhw7nLBi/RJzKbNfs1iXqtLtjnF/P9HiPyO0ZgbRLiPixMgsTCB5qUAoROCwq+cLXkRvR8HyZdUfDShOc8DDalvrr8zrqptRbYOHa9oK81i5MFX/Oo64eBjh8ZnRGaBk6v3xJOI8i69bq+xKuVptBZtaHBnjVTiGUmXux4RntbxEce+gS3F8Td/xBq3sqL1un9PG9jDNoABiDxPpfBW1DZOJiiJx0Zz3QdtDm0E5QCRG/BL0ien0aqzOeQKbwmm1NJ+kGULNcIxoP0SFQCAmh3CRsH5VGznR1GJqWU0kfZl1DYMd+Jakq5UObeTs8XeYPGBM6IcNojOtHVE9kGIFbrMCko6Tq6hq/3PLk27eTkQ+qVID7EhiDPy4baYeyDElS8oFnpT62X+NDEaP9ZCdsv8XNPdejWehcE8ydg63S2V56Zy2PlDypBxI29u7adzKjo13SdpUkb0iWFdT+fSeKzZo9O9YOoYcbpBZH4I1DPJfoLRXEI7AtGCJBkvG3KRwHQ4kK+qgTWDElO6ctZ9iZlq/3zPWcr9d/rjPyFQ/nODybyQAtB12nAtcD+tsQ4ygnUcS1t6vQxTIkFk5Ej8ioNJebg/Rcjbaq+Ff6lSchHdFD88xxQXQaGu0W0Oxr+/20+ivPocYuuRcyWBcG27IsqajYAKga1F3dGclAotWEfY9yWQvIE/veF6ZoKRJBKYio74++kmgxrEYlYTRIS15U1Zd/twhOGwiDWEamw0/PV+W5wnerIayYgpVedo3gdk8O3aMZ+m7Nj35EeKlBBq1ooRa60l3lcutThS+Wpb1j9drMJr4SWIQ19d4MiWND2tO9ibsCpqCTQhdeEc1HohpAVZ+gS9sh81nmDptWLxArQwVa0AyDkvrbklC9Pvyj/CEwzMej1CtO2tF6KYpjv9+tSMrw/5peLyjsPaIB9y29/cs4qPmEMXHvjcpABxVV2L8JI+8vSK+vHBsCEjdRysI/i8A6iOerZneIRQH X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: f350f6e7-84a5-41e1-8fcf-08db7d3cca10 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:04.7219 (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: q0B0zoJgrBIcHnms9KjrzkIvN8uO+DcctHSop4YiSRYjifrZkM8cInL8SMQgeXOOOxirphxjNr7lcIreekn5Xw== 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770574624133031647?= X-GMAIL-MSGID: =?utf-8?q?1770574624133031647?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li Acked-by: Xu Yilun --- drivers/fpga/altera-freeze-bridge.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/fpga/altera-freeze-bridge.c b/drivers/fpga/altera-freeze-bridge.c index 445f4b011167..bb6b02ec2d21 100644 --- a/drivers/fpga/altera-freeze-bridge.c +++ b/drivers/fpga/altera-freeze-bridge.c @@ -213,14 +213,12 @@ static int altera_freeze_br_probe(struct platform_device *pdev) void __iomem *base_addr; struct altera_freeze_br_data *priv; struct fpga_bridge *br; - struct resource *res; u32 status, revision; if (!np) return -ENODEV; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - base_addr = devm_ioremap_resource(dev, res); + base_addr = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(base_addr)) return PTR_ERR(base_addr); From patchwork Wed Jul 5 09:46:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116042 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1752303vqx; Wed, 5 Jul 2023 03:00:40 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4/yqYKVUWpim4IxY4YTcTfBP+OX5KtlECjYDhPRYgz282SDXu5IpUl2ZeAqScw7UJKc7YX X-Received: by 2002:a05:6830:1e2d:b0:6b8:6ce6:e7dd with SMTP id t13-20020a0568301e2d00b006b86ce6e7ddmr15608812otr.8.1688551239744; Wed, 05 Jul 2023 03:00:39 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688551239; cv=pass; d=google.com; s=arc-20160816; b=AkAJK4K3+UDKecOhTfMadefOT7uNxex+1o8sgofpSainHAkeq93QYWIGv9fFa9fL3T F6WLNG8+y4IPmKvqMVk+lN6XzW57iN1UnESWN41nZ44wxCQCybc+meG5KcxIAX/vnilA xiCyN+exRBUq6ZzU/MrpKMEOBenzvax4qASSCRz9dBVVF569BaYBqi8ghX4qfbBN59Ud KLAViUu5OgS9L5KNnk/VpA5vv7K8TYWi/bBlIgC+GXK4S3ngonZcXWCIzMo4oMAXh1T2 oNvKmAhcUN0wBzsghcH/YQ26nc08MuQ71gLq1mq5CK/enO2ZJ1HQUtxrr/5g/14DcHMZ lGjA== 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=ntc0WA3RegtqQnRTN0Tly75aTIgb1dBhmrZVsmV7fVc=; fh=FeT5G38czCxbFra8wh3CNM+BAh9ogjZ+EeOzujh3CE8=; b=AiJySSNH6sP0C6tJ8ihCSq1hXgtYkkOVFZr9pM4XjwaQjKojAH+A2Wr90GeI6p/m3d ZQxkuTd5D28ovRmCpIXRtcfvIwr4PnnKCh/ScCqbM3We9Fj2/oiFlh0s37Bp0jNCHjSN hSqTU2BRSbmytyKOrv0R4Nn52nWjuTRHzumHIA21jmg5j+qo1aDMdDSHkEC18r3/nmVi zajfKhy0SVSuODdDXXMLemKKdLYcal3M/F10KUTRRr74HbEZSwdjDVHActgAHl0BlFr5 wWy4IC2b/TAgf8e4vgtpo+l14e6ReOgS1gcraMFYYGKCDVdj2f7YBBX68vDHexcT4+e4 0qhA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=g1GEXn3s; 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 a73-20020a63904c000000b005572b13d228si22436502pge.277.2023.07.05.03.00.25; Wed, 05 Jul 2023 03:00:39 -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=g1GEXn3s; 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 S231237AbjGEJrQ (ORCPT + 99 others); Wed, 5 Jul 2023 05:47:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58192 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231613AbjGEJrL (ORCPT ); Wed, 5 Jul 2023 05:47:11 -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 CA215E72; Wed, 5 Jul 2023 02:47:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZkdZly88RIkGP4LRi2K++CoolxI93ZcVpdDz7ln05u2jJZk0f5C1lmtSPu2aPK31FsnEeLQpDpqqlRbtEGVRfmDIHsupuZRqiYv7eRAmpHJ9iCDS3fUIU78n+teXax9rSziuKjXEAE+3PXsTwKm7YB7JMRzCwCzKB3BolXOi875CjWsrxoR6x4UZ7hcRMO3Si7GWwOjtEs0HIWazdh6xWD0WOkoPOcCSoH3WkprI8hlmwBKhZajCKmAdzuduIg8zW5fB//7R/oRcORFG1+sl+eBZ1ICypEaULjNvjLBtUYS3FyW0jo1xfZMZrJ77cLgidlaLDXjhRR5olVStWDgynw== 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=ntc0WA3RegtqQnRTN0Tly75aTIgb1dBhmrZVsmV7fVc=; b=LoqxKpshUTJXIpudnN8uIbhSPDwo/q6/+HY6gQo9ZyND4RqvuPT6HRdSMpHecdCRadO0PafnyOiExiYfd8Wg032ykFK80rVW9v3ynnFjXl9VleMIDMEU/UFeHGktA0vi0tpETiAqtkV6vsvaXnK7sTjJo0aOAYi2tZOk12Uaha4sjfYB3E88sabTp8SvqJOdeyHsSfIK8cUU2aysTErOpeGbX2YibcPpPbkgD2ikYYWY8QGp7Vtmp1RtZbRgGGEzo908YtBVoT/EPqWqPpzzAm6lkBmHv7zemj8gHH+3A21JCn2H1ywCT89l7n7F7ShLUBAtMpB3xd07S3WVH3F62w== 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=ntc0WA3RegtqQnRTN0Tly75aTIgb1dBhmrZVsmV7fVc=; b=g1GEXn3s2ptXVTrizYRi7lHIG66DB4M4T3WyKpV5fGEqfjFzdtrL2NRDCBiiQcRMBbaAf0AxFtDyO+kj553ZDXLoUgIQO/4cB+CbuWYR8ytkmyQ/SH77WYg1DF0EMaVXJH5VUPV6tqHRcZNZNMEP0fXhE9rUTC9gkBELl3bbIyTDWuqEGII2qv7/5rQLUhueepOlENyHAuQCUTPLlp6gVloed9oOzg/9u+50cIKzSfg/DkmaAwtBL4luMgMZjVeuevFqpxVBrGwno0Tauax49P4vFbvPwn1hxWjl28mtPNGhvZR1fJfXziVE2H8nsOZkcdQWEckB3JS3MEI8m1YgYQ== 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:06 +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:06 +0000 From: Yangtao Li To: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix Cc: Yangtao Li , linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/8] fpga: fpga-mgr: altera-pr-ip: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:49 +0800 Message-Id: <20230705094655.44753-2-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> 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: b11eba2f-af4a-4710-996a-08db7d3ccb4d X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: IEyMpcsyDtT18+u0Z8bD7r1rriaYtjbBuoOcW9amDk2mpXYE8TJH9G7jIlLkl3xreG6oZJUvkJGFPK9Q+4h14Q6J8unQRpoS3iNJTn58fbHhJV+tRHSFvby4MHeR6VjKknU0m7mskuy8Qxs82fhzEzjqUY/ZPiGeFtCoIZkGHWEGD4acuMq3cv6GZTSMldSAEV/6DiBswE72VMEPmTZIZNrvdN6LPvUenQsuIaxp+budfjhD6QiarcxXgmsUhr134LtS8VCTIb3j/GZIAb87Q5BXDtxxTjkwoBihEw1HYC/CuxgHTNzeOvAmia+Dn0bRA8ejAfnEIgYPK4ZWt7n0yAYoygDMuO4gs4fMB4vYwojCxNJdlVpZ6tYJTNpH7YAuhXYvqSgIc24bHNyCVo6CRAbnHhrk4mSG+Jehl3ZXa4WzwjmHywxzYyuaOZnOZuQFNb2lqDF2zTl2Dk8VG2LYws4TqXGVi2mHK16jt/JAHPCnCPtQGp1H+WcdwBTwmQgnqK/VGbaZO26oW23cBzRz3Ud/fN/LlhuK1IMCt7G2wzOLFTouAgCvc5aQ/0rySt3s2wCPn8bv+nkjIlx3Gwq6wY3Zcw8gMUEqB7UlHF8CYp2Ya8pBGisWkZzmH2Hbbgbc 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)(4744005)(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: 1sqWD7EgQiMXYirrpZd2KYE//RekrBOK8tTl9Puasxoj5mCou9GUjmEzCz64CFZ+cW9W5snz1/OnQg60INEayGrojvRPd5nDlCZDUCkMTLmvAROalk84a2b8jCmRSE3DCpPxVNjHlW+VGLlq2x0vvp6O0ciF6oPoHu5XzGqQB4qLILfXjpuhqiHuV2FR0tczMIodsjYrr0xiJEZrTiI08MUNYXo9i2qA8cicGNMvCb6EjjIziaUj8moNoaWcLXxWrYwVc04hUC1fOLJ7dIgME7VOoKRxGy87/qRGg6CXNaLXTHDX6/xcmivssmAhwagn9zR4BnrVVmtrSKqRmUnC2SVThqzK3I768giTg/CjMyO7Ftf8oKwjME9lnsj6prBrPRQXdMz6lfnnGjSedunWM9fp6EVSylUH+VNY5DnANRqW5VIGgtCOqhDS0Ygn9lUzBnr+Xu4jvOa45Uh7TdvcV/iJPwGN2ZiT1ZdBdEAnn/QP11D2nArguGYSIrzGEd3mLYSs/5EJzrTtQ0DtnpYfFIKWyyA2Cv6vU9llLMB1ndHfYic6EqebaEFEeRjyflAzgzlDbc8hyETIIIUFpoJmqOS8wUgl1vzsoWIdcHt8tYp7nt+8x7xczCBCU6MObBPCmX1wotQeOCTquJXSMA6MgdBNtcDxE05vQKtfXRWxjEcLCUF3tXYBobDoy6dPGiK67W4ZUsUroWhH6VfKRqcYmRHgO4jwrbC0iownWLbvsOH77SWypaZaL0WMGYaCX2jGDutrZ0o8Pu5YZXk67dTYdy7PX/2z5TvYVJD9+KeXF/xp1Cn0qo9SAoeHJuSbUIDooTy25OvxOeQ5AgRhC8iQ/xYwUyyxThLxOokDuJLLaIC91tXtYz3PHMpVoqQj3NjPFRC4wqm5W9ZdMqeQB7QUWFAnXi8ZaFCooSAeq1UF48DxZKQ/BJYJstHvYgvwu148faXiCGPsb9pwhzl7FFIFgpDaMRFhdn0I3ifYpsOJ46eoR+4AG5aKN8Nr//CwLy8PqUnQ5jKuqlqBTORLlOAbWY8AURMBvQRUu16n2qk/v0rgTN1bDfpq1pbfCd3Xq/VpesxgJwhQixUM2b5ovkjeJmIvOS0T60xuxZQQt9wdOK/IFpqMgsVFseC2P9gGEOagbvOrGOn/szWeCCbAfjTgaRAQNfq9LWwhA5Fdj1b94f2a+pN7zs2L7OLQRIxYdpDEZ8Yrw2LbR1swh9+mQAt5yf2Qh4PEqO9jOkRUBqHTyuTcD90zQLGlgpm2u6wPHHALkBFTmZWcpm5Vmc+rUzXjpPU46Z71AiZoMePLuIfClicNOGixMbpNaHhtir1Eq5bKdD0NqYGGcYHMya/obyPdQaWJtfjMuwbFfETdsHL8DxtITsHS2tGqE6SlUaq6/dP4mayGQGvqm1gmxG856surPJq3LzphHYiVl3Luhb04pR0sOuADTSQ5eWUtLNoKhoEcvwg1EMqqitd/qavtYNjsRl8fq79h5foS3TIWWCtLuO5C+7jAEAbbfoP6LwuZKFfj1G+nmhe83ENVe4sGadikAxPWnrWt+yXrhjE4Fi3mOOdWxe+kYAVU1/+VSA7b5zSf X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: b11eba2f-af4a-4710-996a-08db7d3ccb4d 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:06.7575 (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: 9sgfkXj/suhFhXli21R0naLoZfF/eZWCV1QzqTzaI9HUvx6BJ6rzKrJGs4ownjVsShaPECPAJJLmtW6PQDuYIg== 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770574305059932731?= X-GMAIL-MSGID: =?utf-8?q?1770574305059932731?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li --- drivers/fpga/altera-pr-ip-core-plat.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/fpga/altera-pr-ip-core-plat.c b/drivers/fpga/altera-pr-ip-core-plat.c index b008a6b8d2d3..fbeae6e68f60 100644 --- a/drivers/fpga/altera-pr-ip-core-plat.c +++ b/drivers/fpga/altera-pr-ip-core-plat.c @@ -15,13 +15,8 @@ static int alt_pr_platform_probe(struct platform_device *pdev) { struct device *dev = &pdev->dev; void __iomem *reg_base; - struct resource *res; - - /* First mmio base is for register access */ - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - - reg_base = devm_ioremap_resource(dev, res); + reg_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(reg_base)) return PTR_ERR(reg_base); From patchwork Wed Jul 5 09:46:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116043 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1752341vqx; Wed, 5 Jul 2023 03:00:43 -0700 (PDT) X-Google-Smtp-Source: APBJJlGhwk7ru2b+9wYFfqVOplNvL6ZikRCFXW7HBqpiTMQhvpbor5IoGim3R3Vk/pCuy6J794FG X-Received: by 2002:a05:6359:bb0:b0:134:cb1d:6737 with SMTP id gf48-20020a0563590bb000b00134cb1d6737mr11528309rwb.7.1688551243422; Wed, 05 Jul 2023 03:00:43 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688551243; cv=pass; d=google.com; s=arc-20160816; b=bqzOxOOhPBtmRiOGi+tVDP5nKZNZGxieV3Bf/5HfHGV4ly2R7LJxmAaXDAru4gkOTv gm0rY+J3uAV3uYnUuLlkj/37qM3kEPWLHsTixqK0AKAENn80C9dEXrLRCn+QmKVdCEF2 iYEd0H0nq3bOpOL6QCV0cnrNSNysMUcjPcfCBnunK7inxJcHWaUGii1ylKVK3fMlKWB7 6mQaKf4p4j3k2bwV3CNvKFpH8mfldYkiBAoLnXLUZv5yPxMun4lPMYgYFwJ+ZIQmNHDr v9rX/Fluer4VSbFEWqmp42WwDWf4UbgIVLVNcybAZG1HuZqJdppE0DWHVL2PFV9Zb/dA QaYg== 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=JH7WIui+YXzkaTFLDLC5c//rYVZ2FNftzQliH8j1Bno=; fh=wkFRp6WArbimTTYbImvPFSniENv8+paRpxHahFKiFOk=; b=k3EUl/BE0KRtIaVXV0ZCTKOlgykX8QyXR/vnF7vRsV28zQ0iAlDfUeZchhkCQwAvPk tSUJqb6KQKSkhmjuqvfO8c4Y06MnwBkIozpsEAS6WRNqk7eWdaEYI8/+d9vzwRkvOftX XddTYaHe2af0+hNrJuh8G1cpynjV7KkFBkze/w1bd4wEdlhNfe0QtPQAI5+Zf/BWRs07 o6Bsxm3sLZTQ+f/EGQv/edK+lny0rRqGTmhajv2epVGSoxrDk/O3pDNkGd04Y10DhXpM /pCAhdfjEXNmNMBxMocHcwd1VTarmgcVnfxGMiJhft0S1q1Qk16S7UW9pGqHocQb9vDK F40w== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=alA9Tti7; 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 dc3-20020a056a0035c300b0067c03d5624csi17440983pfb.293.2023.07.05.03.00.30; Wed, 05 Jul 2023 03:00:43 -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=alA9Tti7; 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 S232010AbjGEJrT (ORCPT + 99 others); Wed, 5 Jul 2023 05:47:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58206 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231955AbjGEJrN (ORCPT ); Wed, 5 Jul 2023 05:47:13 -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 155CFE72; Wed, 5 Jul 2023 02:47:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=P/fsdpLv2MftUE0ZQk3XohB3zxEy7/sdgCvScn+J39sWismQ7qWtk/0LIrxwVdbEbBnB5Ltf7GTCBsS4RtXG7haeH88g9XJwkax1toaF3cnXE5Ipx8nBYVGnsy2RPMIvv5xVUFuqcOUxh/tIuSFZVi3nqrH8Yiu8wZKt5ThpjktdzZlVch8nErwidM0fHe2D0n7GgjAfuSl7vHl0XCpUY22KYqci9vxsnZHYgXfJVccrqqKUPBTNuMHKwAEaqMJbswXMtkpVVJTeiMF1ThMR4bVVZ1+IlS1Wt1+pvdfxWkDKYwh0Ajb2nWi1Mjgy6Lj/Bjf2XPWw48n/B515lpxD7w== 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=JH7WIui+YXzkaTFLDLC5c//rYVZ2FNftzQliH8j1Bno=; b=nRRgoZ4c6vsmHerSbOQLoMmhe1a5+LbT1VFjuPbWXQkeECtkkNbqqAIh3hcXsc/8Ou58YtXx1ZywPxt2bJt29twedVAzKx/Xb+MJMYaUAdJ5Kx0znr4ct0TbeP+BJzodevikhifs+X3lPJhVzAjRrjhzXhcfUt15Lt3TPrnQSngFbNkrweLOAqsPVseRdAqiRn3dyYG1F0cV+zzhP8A+C1yviGDqot6TozJhGf1FgW0HiMbHZO2wSFoTiZGz7N+tMa01nvEtdx8jdzh+fabTlKfmsDRNcjhXh+0kku8zvGaUw5jxp8PEUtr13D62Ol+BnN9bDG79117pjMrN088mJw== 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=JH7WIui+YXzkaTFLDLC5c//rYVZ2FNftzQliH8j1Bno=; b=alA9Tti7VTtP5+elwK7wckzqFLCMF2vdRCHRTqtAD2Kgxszz308lufTkIWg7iceqTiZZQbI8elhnw8kz8jeB2O5YKD8sJM/FmZXSzQl3bAOW6JyWhtYezAdOmIDByU0tfOBXJnyy6LLva6nmWAzfiIziXUMdXLGnYXcV/QBaiepqJnxjSjVo3rXpbY+aQ2XshJjWBvw76TGxgW85s3DWStprA44qtgyzzEM/94NwuJKBmuPU7B789mCHYp4w+//p0cSMis9Je2MzXCXrQpVAJ5rNvLdnfdIUhugHN3Odr1apu7Bhja1n8uniALExuP+hRLMeY7p04x+Z7UorrfSX4A== 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:08 +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:08 +0000 From: Yangtao Li To: Wu Hao , Tom Rix , Moritz Fischer , Xu Yilun Cc: Yangtao Li , linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 3/8] fpga: dfl-fme-mgr: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:50 +0800 Message-Id: <20230705094655.44753-3-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> 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: 3d93bc1b-dc71-46b6-a4e4-08db7d3ccc8a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 5stK+Bgt4n8V2alhfryfXZPDA8WKijI3x3rY15/+FwSsoFP0zUNr0Hv8koJDo/msTNjwLKh/f5PGmaQ3L1jlFLAwULW+QJDSexxy9crJrmAbc25zqv6+O1TxIFA6QmldO3RkToohYrXqYkNS7eMeBn1o1JzTd+RJgI6leLD6uJmsJbvgKcrX8Q9ZVMGkOGPeFtJwDMytoSa1hMqdcbms8RjgIQUTd+feTNo8cM85QiHKOS7sESQs6/4tuzIx/wrmocrS+POHhF1roht7IuSMWG6J7/uYjjalGNBzYbSuQHd3wn6S0x4N0ob0FAfXSNj2LnbWQGwu8aayqTpUUhKudsEBunQnoPEKHAVd7gmfm+Mz2LAnOPe8zf5Tbe2y0xmYPcTBKbkCzX115tdE4RSr6xr7YhaRoppHd/zeUlMssdiWgrfJ+lS30JgT+nhKeCJQ1JLdV8OiguRC6BlcZr9krrr3CUq1h9ONNP6YyjK0I8VZASFwYnzmcjvRSiO9xROTJMdmdGbvoA8Ow0JpCWJ4+KdmBSNAiGVTbRyuctBafxS/mjM3AiMH++7px9dN45b39NIds4ucvH+hykFXi4R9eMri0Fr09Udc4MFhrCZ7pGifpr1CgF+mt8PMR0sPEWYS 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)(4744005)(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: VnjW0rWsIl5DSWh9Eg2YEcZpeK97ycYufRon+sIeDIQwMimP9nqe6PlCZ2AwyCy2bwWqtGmmxWwzeqF1yVy32+biHi5KTv+EtZ3NCLzY+16Yz/dbW/UC69JpkYgUMOKxuRcIsno57ou91DbPEU8y2DSaZIdEBF9PEOYfJzhtK2X8Y6qUjGzU/dppD5qlylbL+LLjPtP01TysgyucAI8OzZqwUQur8j2dmuscgsHfs4TS1xMSFOgtVOtDpllOtx//LnwqRgvKw5NKdM4PEZfhPxFFcziOrKY+3thA34op5byBQLvYbbbIWe786NF0IVs0vHfvVz7cm4HrVWVwVxcQV72pKgC02s8vuQFut6qZiLgeo7aGANJ4Z/a0bKosuawJW0veIBr0c5boRR0s6gkCfn00liRFF4QgSMTn4VYBeyBmqkNxat5rlXe2Kg2Pqz7cNGz24WZ/paQGd6/m7qIPUmmhqcobcx9i6DnKhOtV/OMf2ElKgoiyyCYMdjMAz8NP0wKbWuo2jmbTKPyjgLCnBmuOh25/jEl536hiuraIEBQgWTdXjBelaAO2lGr6ii0J5h7SAJ4zbmuo/cBeIf6kHstUNEQK9IYNIuSOGFypzVMaKjbl2xb+D8GUOJVZMJfIKbjO7nPwJRiuQLjaHced9aP0cXx9dIUKm/i6Cn/30/0aia+de4XtLN2YZY/FajywnRM0ygw/kppdRKqCQJqsCiV8uSJCD9Au9ILLTuXz4cEV3AiP0wdpPrma73MG5remhO5feyTEcHIS/h+XQ4G7x9+acooY66cH7/1TE+sfg4Qhl9tXUIVsdftNSQ6bMA2PavvbThV88ZIkIvnWw3M+XrtTLZbQciaR3QBHpy3fk2yE4ZF4XHqCIcfRKeF/nLLLq5x4zUbYPtu7j3k61efOkF8Ufsp2ooYsudRkus04DQITxr/EyBiKO8kliBU+c2hCwGdVYBMoRKWWX6OfKx8qDVbFdF15LUZwdBWnVoar2lvC3Hul0zHFyeHrio+0o0q8WOvAWjQJx6GHmpXHE3M/ECG9nk8mkEPRqiFS/i1Sg1bPd5VyagRFhzfVNUcvqX0Mky04MfxCBoRjUQLqkkezIGRDeHj+FENWwV7IOX8aiUOJRdnZg42clOjVe4O21tw2NFlJ9IlikRwoyBbVdyMysU0dZZZueasp54hM92snMpJGtIqrcuDJ/0UGTYj79cwVfNQRCfN+K50ks53yhhxUf9KEg2KDz1qgcQYbQIfvxcKYUE/Mp1sA4zYdNVkSaRaAUoNkcIbWqfDwzHnAvepITzk7R5p+tNKT5pfqFQ6DGcuJreoz+qH7/2gHxtcK0WPoCMMfJwzW4iyMUiphSdgYHSGa2WAISiQjKPuOhYrJyD9jM0KD+0Q3pqA0JjN4/Nou8ObHpcdLdhGOSSSx+yE8MldNf1dEYfyaoD+LcFMm4EieuGfOetzlI9r56+/CAKQ1TLd7h+BuRLUhuOut33wWzz9TU0N0c3vinc3m7gaMV/3c9K/KO88ULjHf4EOwAHoauy6nLBccN0wSETSI72r/NPWJEwNX+Nw8qg8/C+2USrRfvlX/MJjokqXAyMo+3Rfn X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3d93bc1b-dc71-46b6-a4e4-08db7d3ccc8a 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:08.8178 (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: SFAl7fBbf6vmHv2sjUEK4qgX7JFyzKvl2hlj5C+9PfOTCtCtfnp3m/Ecxz0lP/syn4Ii1IUpyADAEc13wSodPg== 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770574308474234876?= X-GMAIL-MSGID: =?utf-8?q?1770574308474234876?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li Acked-by: Xu Yilun --- drivers/fpga/dfl-fme-mgr.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/fpga/dfl-fme-mgr.c b/drivers/fpga/dfl-fme-mgr.c index af0785783b52..ab228d8837a0 100644 --- a/drivers/fpga/dfl-fme-mgr.c +++ b/drivers/fpga/dfl-fme-mgr.c @@ -280,7 +280,6 @@ static int fme_mgr_probe(struct platform_device *pdev) struct device *dev = &pdev->dev; struct fme_mgr_priv *priv; struct fpga_manager *mgr; - struct resource *res; priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL); if (!priv) @@ -290,8 +289,7 @@ static int fme_mgr_probe(struct platform_device *pdev) priv->ioaddr = pdata->ioaddr; if (!priv->ioaddr) { - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->ioaddr = devm_ioremap_resource(dev, res); + priv->ioaddr = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->ioaddr)) return PTR_ERR(priv->ioaddr); } From patchwork Wed Jul 5 09:46:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116044 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1753432vqx; Wed, 5 Jul 2023 03:02:17 -0700 (PDT) X-Google-Smtp-Source: APBJJlEU5i3lCdeVW8A9CcNz7U2e98WIeSRAZ3uVDRXfy1DrRy/4bEnyFmtu8vSw/oLe6F3eE91K X-Received: by 2002:a05:6a00:1506:b0:668:97bf:5ed7 with SMTP id q6-20020a056a00150600b0066897bf5ed7mr22820851pfu.22.1688551337327; Wed, 05 Jul 2023 03:02:17 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688551337; cv=pass; d=google.com; s=arc-20160816; b=ih8KvkMyCiuNHt54q0mSm7U1dOnBNKISb0MyWx3Exrkh70RBC7uXaL4Qj3crubSOIS Uxd+yF7grhfj8gaQClvq3pcNGIUQjdYWwF3AyX9aX7ws6VW2IwaDq2pnmD3NAwmqs5K/ UYZKiRI0MBBM6YtzMnUYd6UwAJZnL+EPQQAGQAR05zbqiHnOPit/oiEQUugPmtFc+oa9 2SCgCryryPxOYbZBvq2R+Uj7ltHDnfDjpjEpHQ7Vx8u7zh6evxpVyD9Iu9eqIjATmRYb oPJ35gvQa/pk8cDJTgt+b7khQzeATHG+4/1A1PgjsSN5NNvnvW0NDspDBxTiPFDWGkHk +zLA== 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=Oi9xdE4rc6Wv8p4pWdX5mT3He611Xszf9pkmg5rnzaI=; fh=FeT5G38czCxbFra8wh3CNM+BAh9ogjZ+EeOzujh3CE8=; b=QDsyrdr+4TYbwcrqXjCretIx3qA/J2t9xoaKMAhuFw/wNzEwOwtgvN0W6bq5UJRMkl UEHqnHBJyxM6iV4D6YgUPz8tH3FJDBY/V/e8EclUbZHFv+Pmm8ZFD2Jxj9tskLy+yIJF SFwBVXEQkj5etCdM01FTFsfxgSZT+CnOcWSJuJBUtudbxIucHf/z/XesTKCTIfBYZysR fjc7iEg6wBNpw1TTgU7a8lLgsMQA2311WcROJj0unlQEunCilIpNAmj4vbwmQgYmUv5N 1YYGl8eSMplntQ9127SxxC9S1eqJ88TG6lc1AxkoGHSl+H9Ka6YyL29Rh++dMNM4ski3 EjDg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=jfbF7R7P; 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 f5-20020a056a00238500b0068219eb2796si14241618pfc.267.2023.07.05.03.02.03; Wed, 05 Jul 2023 03:02:17 -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=jfbF7R7P; 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 S232029AbjGEJrW (ORCPT + 99 others); Wed, 5 Jul 2023 05:47:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58234 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231975AbjGEJrP (ORCPT ); Wed, 5 Jul 2023 05:47:15 -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 6E38D1710; Wed, 5 Jul 2023 02:47:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Rlj7ZP+Kd7qcm2IRoQcCVfUvYnE6RwDBMsHc1BfjEi8YcKYxlMQ4KL5Lwey0EV5XYD4le8upzMcTcB/Ip49lC45Tr+QcmwczgdmOH4eW5Pv3SXJA5LYZPawvqiylmXY41EPqEaXQOwzilqBhmnf8S5CqLGMbBN3YjTnd9IYuBuENw9GW+nkjknD6r2Pg8QDAoeEkKisjnXZ5lap/dLT4lp7sOMHhNRXoWkzP1eY3nLFzeV70UmTAh0KGcj/G3J0kse/AfXhSgB+JaEMxa/R+/22qPB3jaJ+tG0FMZr/NRU5FhruQ9c7vPZAtWKMrGB3e7lP08j7rlQIGTL/R4nBERg== 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=Oi9xdE4rc6Wv8p4pWdX5mT3He611Xszf9pkmg5rnzaI=; b=C6Sut4ogx6pcWiRpI7vKR3+Xi/Cvf0ojT9MzciAazFIpKbhylaA3k19qRcVTyYR4YXpx8ovwdl2tkxCGg/c4Ulzt0AucCy/EAiIGZ42vzAZH2YWzYDE7fCsLFO0REG4n0/i2PXlC+h5cEkViKeRWnVk/Zs+KTGCg/CoiExEMRh+ZXBrctSd6pXiRsUD/Yi6Cj1YyMjOam8MAvFcxPWd//NqlTqWveuk2NHSwngvIccf8WJYb3Gg+YH6OUxckjr7xB4rhDblk6a48d9UxBmOm6oT72ML7jrRstY0OJKGypiw80K0+P76/zsINgAadSoL9MlZnOwgg+p6ilMdaf/6dCg== 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=Oi9xdE4rc6Wv8p4pWdX5mT3He611Xszf9pkmg5rnzaI=; b=jfbF7R7PtcLpz6uGj3PNZ7uh4HUurSo2TAZdaS8kBm//0YFE8V97N7zvciqE3kbMDeg2h0M+rDX0s753893FWu3k2BxAh0MwmYY0SKj+pbQLoH5M+6JpUMAnO1RLb1NtrU5RHIekcJmghPxyuBmJJZM/FEDtVxw/0NUeDSH8fVaYHttPNFOeeQisxdKJuTkw3iNx7J5nUdVf1dMYrc6fguZuHVSYjQcWWwLz64TV5zQl/Xp3MHdw/JNrbF2ZJk4Fu3QpqJMQEPrFRNScoYRQmK1AVpcSPIoYEFHo+EpRQX4WdnsSxqbaNpbstmK//yq2EbINPtkpI+sx0pMs+6CrEQ== 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:10 +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:10 +0000 From: Yangtao Li To: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix Cc: Yangtao Li , linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 4/8] fpga: socfpga-a10: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:51 +0800 Message-Id: <20230705094655.44753-4-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> 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: fde6ca75-b463-44e1-c199-08db7d3ccdbb X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: PQzDQdxIwCFNTEW5GTeNj+uAaKT/t8iO6+++jh4/iok9u/q8ONrnbUOrp2y/lx7cxavAmIplJb5GGf16PuHgJpTrxDfsAAgQn+LQoO7qXtwmZ3L3W65uJEqCmjZXkC0ttbyUngVh0N1EvNqGGFIgn6c/Ox8JDU5K4wLqJfJk7+IR5C1hz1hDK6lT2sAriLrvnro5G8yy2JPtyOkUACqiJmD6fBpHMv3jgqEl69EUBGgYbCzDYO1t5c3NOpy+i0H3dpMoXUDzLcwIhgDN0D9yLNryHvf6EmvXTHs4sa+UWSuiuAc2YdMTqGTsxCbNSPt/0wyKgpUgzwttXP8Y1P3Mgo5usJzpP0X1lI2O5yWdWr89qHErk4VngkW16asSpyxWpuL04uzumVj5xfQGnbPX3O9zyZ3lHbKbFNPI6iETHupFpcR8j5bAOHhnqOgE2FgGSzmatjQiLsBsX1aQldgTDMSPKbP3Nx3C+1oDuVGjlQbhBkAhvspXrv3BnJSJAPVRlle7pN4U6t7RI8yhYQbEtM+UTMldjbxCHzFlD1WGn1BYXGTs8YorO18h4csjnXLVK6OkASXtbEKIbMwjvS7Dix3rFM5UIfRJn9E6P9jYPy8OqLWhz0GICpXVkKz9Yz9G 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: d8b/iMZQe5Kbhp2Oh/6OwvRpXO0GLwzv4hWRJ2cY9BAlaF2+Qe4Is8XzmqmpTPsFJ0j/pHVWxrj104JJW1UrYDqiRLnV7dMUoe2I6XQuV4EJMdp95faGH/2s7CKgbowN1QZxXrYEAbMraBqg95V8QZ2qZaqkROXUljCmtV8X99YwJBNfd0Xq3tkmE8eqc6Dz9wgOdyrqFnif4wSEVH/NM7Q8GXTttWHaBNByyBStQeoQBCHDXfLAQNI95FwALmOinVemfrhRb/saO0MoR1T2MChw4zhozYP0vNqmjCqyHy/ixTzF/5Gde9Y5H4HEWpZG2T7ehMv3x62fstD0kZKY5kA/EX3DzTwDjsDk9vGYPUyRfVMlzgYWRbDidd8KYgxn+7Z1+hnONtu1h4pXRAOVOn0AFj6KVPntGkJH9W4kOC7ulBzm+lhpr+70nQ8Yvq7HdzF5jNtrkyU57wRhFGK87mfiWAwDjWEFkZyLdpVFF1ThTTiN5eQ2bf4OlasEXb0Tg1367D2LXjTJNlKxZ6w6Xa0wXMajTcwtzk7mvuMMcXjyAEGuUyDbBNFp8F17EG/wjZS0NZeptQB0kgmnmv71jjUlXGSxDlyFsrrv7ylIhmGb+N4RMT+aGjR82jWECbPgS8K3dhHHkGqRF1fpqgoUKbGVK+d4ddUW7z7s97vcNijr0ipuoOv/+WhljVIQook4mHIuF8dg90XszK9l0pOlrUD5X0SlD+cx7+ZYAOBccFAAQgJhtWVnpedYJRSCGeaiao+wx7Iz5/TmMALvfLhePUfPJgNbWn4rbwM+m0AcWO+PNx/qXAbRXHYF3tx7T0kZIPIJ2qmvUPIT62litDIqjj4Hyr4xLXuFMzF6vKkog7XyPrpBR9iCk2cCsnHPvhXeVhmEx98Yh2j7hiws6YDsuBR+ANFk8cB3YQ00yBHdKvt2EMI1ewVqZTcOQ2wVEysS2mkmJptZGTwksgvPYXPbCoyL8MlFyaNO9qTfrRh1pXIwQTwYyxNliDhu/IZwiN5eZXMgse7XqP8fMSFHO1juaMJj/8arsQzdZErtRxTuArNX4kip3gnjW3MdyOdJL29gvMDOj1s1ec2+WOrdYcEv0YD2cZ74XZnlig+hiH3uOqai6sa5H/E1kqnn8BvBCKRM3ybxdpC+t4Y+0WiQBnD16bDqR8k1lw20XXO8gxLikOMCqdcVhzAl5y6/PB+Rw1IYDpz9baLrc/IIWY+VPlRawWpiWRlyJ3b/dtXEC1V5BiQ94dNDqPN5EsLi56Z3tgBXs4FLiaVf/bBF2z2yX4ElKGehuPhElzpCwiE1dHI6MCIHjawGalQX0YvmSWPwQ/dEaSWVa+lAgruxa+A8U1P97z4LT5WxvgZ+gx7w3uEZ8v+IJM4lli5GZEvurlA/z9qQbThcCkB0k+JQPkil5K9IamBg2SDg68G0CG1Gw3a9g+35WONHQrpJx/kSTFcetjIrfPb1U2klTMTMnJxiRNEOrkNDnmLgQa5cgAO2+QlPGa3LjBsSVI/ol07EiW2CrglHphqp2Cctryhi9IXPhSdVJBlFyako2L63jEnofF72GoG3HmZKzu1VX/OjF3yONmDd X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: fde6ca75-b463-44e1-c199-08db7d3ccdbb 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:10.7790 (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: pSMxa0wnxcDdssy5RBZZ/foWOk67HYbj4nGVb07Z2bKpNq5sQwYJK9pqmkVnMsu2NaFvzaY2uhCsB8qzIEkkCA== 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770574407032946430?= X-GMAIL-MSGID: =?utf-8?q?1770574407032946430?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li --- drivers/fpga/socfpga-a10.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/fpga/socfpga-a10.c b/drivers/fpga/socfpga-a10.c index ac8e89b8a5cc..b7b6e0bdb3d9 100644 --- a/drivers/fpga/socfpga-a10.c +++ b/drivers/fpga/socfpga-a10.c @@ -471,7 +471,6 @@ static int socfpga_a10_fpga_probe(struct platform_device *pdev) struct a10_fpga_priv *priv; void __iomem *reg_base; struct fpga_manager *mgr; - struct resource *res; int ret; priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL); @@ -479,14 +478,12 @@ static int socfpga_a10_fpga_probe(struct platform_device *pdev) return -ENOMEM; /* First mmio base is for register access */ - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - reg_base = devm_ioremap_resource(dev, res); + reg_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(reg_base)) return PTR_ERR(reg_base); /* Second mmio base is for writing FPGA image data */ - res = platform_get_resource(pdev, IORESOURCE_MEM, 1); - priv->fpga_data_addr = devm_ioremap_resource(dev, res); + priv->fpga_data_addr = devm_platform_ioremap_resource(pdev, 1); if (IS_ERR(priv->fpga_data_addr)) return PTR_ERR(priv->fpga_data_addr); @@ -494,7 +491,7 @@ static int socfpga_a10_fpga_probe(struct platform_device *pdev) priv->regmap = devm_regmap_init_mmio(dev, reg_base, &socfpga_a10_fpga_regmap_config); if (IS_ERR(priv->regmap)) - return -ENODEV; + return PTR_ERR(priv->regmap); priv->clk = devm_clk_get(dev, NULL); if (IS_ERR(priv->clk)) { From patchwork Wed Jul 5 09:46:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116048 Return-Path: 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 + 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 ); 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 To: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix , Michal Simek Cc: Yangtao Li , 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> 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/YPeAnbxrjtexIdj1ntC3CJ9EZhe64XvilqVGmSuSHygyGDOoaamIhLltuNyEqGL2Dml6J/6+ZSJE4xXOpZVFGZzMQ5LkupHVFlYzOcENATM/8DeOMOC2QSIsBrFGZ4W1pxi5l44NZEIKAZU/V68V7/L++Veb1aXfBiTxaoh73xEQqJyDTW1guK71OONYVPCeK/4U9+rQrr0T7UJDxPN83ormixwjjJWnv1iALrlasZmuz3GyWHltKnHrogEVCNi1pyhrtsGqKVnQIblbE7WRb13cYauFnXPci6V57VtGhMHw+qHgQ6Fpt+m1/inBaMhjKy0zaq1DyvpSl22xw35uCNNTp/83L6DThpm5Cy82aeGSb+RxlvdbzhiALqmGLI726LGkzw6G3X+53Xk/A6h21+6+66w8Kdrin7QfzrefbzJ1o5Vmr1fwyMp7MWMvLQt2jmrSsTNH9jPPcaYMw+ehsTlehVh7R2f9UXXC08HjbZ9zxrieMZm0WZqrpsfVJl08k6uHmn9VER0Z2+vi3EIGQhGTfMZFvjgi72Kco7faxvGo2EEi5tcXK9AtCdV30ztAg+daBuCQ/MZ6Eiyk1JwPFQEVOcCpSOH4eKWhS7xfI7b5EV4PUEHK9XF+j65a6vtg36gDoHQ0ZfdLaWxq6cHFUOyBqab9G5Bp2XTUUdOPm6D5QXP+cXcr48ZjzziNB/aON2iw63Fp5EH+Y/otByXITZ07eWULkk4vSosqQxkrJv46Uk0lVR0+UnR8FBMQGTVky849IFVeeIx8GIiqgOcrk64FHn6ZczjY3bhiIiSSOzgRIqUAGEozFBT0n+2V7CAoT6qBUPMcWURXVwSg9fMFHKsQXq4/akaS1NYOw25URUa0Bo07FWDpAlDY3stQ6njOsN2OJAMzsmutZwiRRkhNR8vm7ykI8vxgJCK4PFpUZY9Ew2Zj802qg8BvYGwz9aZu086UbOa8dd9Fuq8Hhnwl56MOja1jAwCUxxNiQdlYgDEMLqM0WuX6BcmrAFYgtyTPoyXmBVzbm3oKI90NUYQyRB6IqvcJfz8C2IRf2JC/TUsjHG70iG3za5QawQVO+NlWk9diz+8N60ArJMhzSu60HUdtMpcrtaq24GmgZEoUiE3DKHbrbsU5DNLkdHdi49+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: 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?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li Acked-by: Michal Simek Acked-by: Xu Yilun --- 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); From patchwork Wed Jul 5 09:46:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116060 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1769853vqx; Wed, 5 Jul 2023 03:37:12 -0700 (PDT) X-Google-Smtp-Source: APBJJlHW/Qdlo7hQt3J2LL8Au1k0WNugs3xBCoBGpKHU+wRO7HwdUSMEVAFQI3gZVZNTdW4N5nnX X-Received: by 2002:a05:6359:59d:b0:133:ac7:c847 with SMTP id ee29-20020a056359059d00b001330ac7c847mr10431433rwb.20.1688553432101; Wed, 05 Jul 2023 03:37:12 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688553432; cv=pass; d=google.com; s=arc-20160816; b=kGsq1aoBqrjVJ6WkHHoNtE8/Kchi3OjJcyR/K3z2cPSpaTjzslYh0h8oyZCu0JnF50 ZOyPjfZbQW4+VNqQ4phWN+rQWWrLa8bQnAjbmYEgo8+zdm3xWArrBdEXmKUye6WfBDyn ZGT0f+STsQJpbhXSKHyL6X/LsQHajAbJxKFX2+Ilcb1CIWqvlL2dzhkFzuZ4NcBrsrCk 71YCPCO47gmAxq7Lq6Eis58V68PjfHo4mt5WEnmKy3giuAp6RyqI4OWADJMQgN2BaNj3 A/c2ukQSSwVKBy7FcHOPuctepz8EINQa7U153+80HEA7q9r7cY5uWyRqIRGIxdrNMjaB AiVQ== 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=QeBOksdayoUe7n1ygBMWX88dn19f22cmJeOzabc/SqU=; fh=FeT5G38czCxbFra8wh3CNM+BAh9ogjZ+EeOzujh3CE8=; b=TziD8ZKN93hILhDXUti4fu8yrNPR5HpzLOCodUxa59sbSBjRyXkuCgxAtAWoTJO21F WcrB6RrULjImOjpqFdSm3cnOJa2xTwTLvioJWhkFzvGntVdTjN7n8nOYboYPWRBAeFue H6BEm7fVlI+bGDWGSsGkQKZAzJ6t8UgESSZaEZaYecs87/Z8ifGnJp5hWk523bN0UcqC gGscCncgSvfRGjHNU9nvUTigNhuNOA0SwWbWCRoTzGIDzhS1oBOtvrJqh3nabqYFA0nX npYumc6k506jzhAjDCp/mQIHNdqoVx8uCqNGbyzDV2vFzDFGrLeVZf07ycpXAY6XgFsc Vnzg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=jNh8GtVE; 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 eg20-20020a056a00801400b006765f19e479si10710278pfb.132.2023.07.05.03.36.58; Wed, 05 Jul 2023 03:37:12 -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=jNh8GtVE; 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 S232165AbjGEJrc (ORCPT + 99 others); Wed, 5 Jul 2023 05:47:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58620 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232035AbjGEJr2 (ORCPT ); Wed, 5 Jul 2023 05:47:28 -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 A294F198D; Wed, 5 Jul 2023 02:47:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bqZ6rNPGdazHsD6iLi0XkE8Z0CGJMvX3mapfg9BESCgWmA2SklpOPnIt5HOJSH8LlEu2LL3N2A7nIMqYk9jgsMkVWdAAaM+izHF3+j8euHitto+cysx24gd2ihtSjIeBDrkA0cBWZJ8LiyXeHNruUhG/fuWHIfkwh9Yjf6C1FZ+DMDJNFROFQwpllfR61nHYDFk+hxBNreg7F4E42XmjQ3OwrZMAk1y9prxMsYvzbJ+2Q8sL6MVk+9ajtST6+XnLzAWB0D0ucW7C5aZpfdfGgx459jFz0Qfcsc8zFvpxirwVJgnENIluLKirp8DcrHw9v9lQ+qJD+9H7UwR145LZVA== 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=QeBOksdayoUe7n1ygBMWX88dn19f22cmJeOzabc/SqU=; b=FlG3kDbe3AMQX8t4VJzmUXHdjdeykqhqVtB1Rw0wdwWkuddTEJNNAbBH6lhnC63co/KubQMLusOadQjIifPWcMAcK+aBkF/IPhvKW2ygFsb7MYhcVB35RMk2zgdxvGNzleLvlziKkamH9oABIBsnEccP2FkgJq3ozZSvdY+EJgX1BxU0g/xm5pbWCzVDc4XUE8By1uhBrkL3SYEi6v+4s8oq6sFThbWH9kMvlr86tNn61/shnrahHxDJsZIEpv6lEUxsEejIFtCAHOZ3Z3+hj+4KtsrSxyUwMHSmFH1x4nPpBIffzlDIstho8nmgLoJ+l0B4U+4bPIkpCDcribNJIQ== 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=QeBOksdayoUe7n1ygBMWX88dn19f22cmJeOzabc/SqU=; b=jNh8GtVE0LyVK1PG8/70iBMASszyrlFzizXNhaKOG96kCVpcC7i/PtcRrxXw3+JGATe7DrpJqItj5dxI1GVcx/gF/KR62SM9//I0/ZBEY9Z/+CukR9JvhHGVkubn6uG48omVItUumNV7/axcWYDbm3A4zZQe2G20EbSE6m3m1slasm5zR3Gxk7wtRObTGlhKGJCDNlTTAQ4jSkQWW80Z5IhVRQMR9OdCVBoy+NhVsN0Uo+XwxIaN57y0V/gl0qNUowDjuxubcIuJL+yJi89y8Mn7eHqRxg8YAbsCfVB+eFCwc5GFIb0XG+y1xi3XEFsUBLT5P5euo6ivVq2iSH2wKA== 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:15 +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:15 +0000 From: Yangtao Li To: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix Cc: Yangtao Li , linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 6/8] fpga: fpga-mgr: socfpga: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:53 +0800 Message-Id: <20230705094655.44753-6-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> 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: 10cc13a0-4db7-49af-343a-08db7d3cd057 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: t5XHGQgRwESP29a5FGOdsghfrwflt6l7PRTHWJX+8dgc2l384iJgyfZ3MGWs6v6MtTBQrbPKYROVOzV3Z3ERBsFH3/47vTX2fYEhTOmjMmwysqgbqKxd8idP77S6RiqZf7M0ortlS3jqyvzyFaP1KUXIT/RQsk3mfkwcD0uYXFilY+zPh9milgOydnFdRs9W/OroWYm4JzXm6lNkd3W9G1tUIQE1Dm3NE/04auZQDcqQ6owGPwN6SsnVtVb+7S5GUugnhKPemEI+SOKqqthcXiyyOQcNU7Spfay7MLNsopY7yo4OvCKTcY/9gNhWLueVVEFBtdJJ0p4iW2BMcI4KwOHJXTFdS1dl7Z0j+P9vy6JnvQjYbMCLKWU+wv69DTG0woiKt/iGOKnUju6WSewDlxj4AFhOwRVzlJ27gCePBafKlYyXyPiK/HR/Hj2Jw7qjaM7C/6OIXJRCVBm0gIVqq/w8Gj6kbrN+hxmWooR8+oDohCs+jAHFwmATtmua5TpBHqiXgTTgxL4zjKaPe7zRbKHNqSRxIBkgA931Gg9PSX8Vb9zu9gl6S4Eg4/KJo75ITio7b6ZtiQmf+qT4aYavZPjK85vZufKb3nq3z7zPyaZ35/P19W+86Dv+QvqbJTnU 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: sB/QgiOojhdCNAfgT1BXCkx7LL1+2T6causTnpfNIGHtR0CZZiJFLvqanvCaXbHonvgUwrvIH/8O0zxaW8o19uQ1eDqYeCqNXz9utlQfuYEJmugcxNRTi6h+G+G7N7l/p2A9hbMxLxPkz/WDYHtHJSP4nnHqFfthXLqC2G1fJ3q27mojHrYEJ1wujCmgVSjfiuRR9h5/g19gZDXQ6BZb2F5LHDNFzfEZBUzGunCeIrJAuPYqHUHtmB0AmJVr/fplQThNdo83MMRRVAt8L852O6MO5Vno0M3Ju30jua9Ax/wg9g8vBrFQuk6J58qWZCQgXGUcyav+v5vTJWTtaXV9XWd4EJy5mdprN8o0Rsduo1DAhdiZlR32y3QCdKr8CuVvL/Nxrp7Ou2nc1ca93lB/C0IYnxsKy9PS1PKg+6P8lnivjG00DZLKjLgjmZmtKrWNucwzRkdRtw9FHugqhI/FYnUCoRWslt+vqH+swOZ0GneMs8wRs7kGvUWcoD56/sY/jYlpWmPeVZMg1OKQkcSh/QEAb4iU8Je8HOCrr8cdGKOXlYR/39WWv6uhHXP+MMkx4knmBZ7vJMLtMwNcZUkXQ20T5iqTAH2fFAuqZ01DmlKXm/3Mxs2HjlzKHUMptL+atHcAhnoGhapSU9wZD9R3mhfWalEZY4Tdt0G+lTP3EbCZbZFrYQeMaYEfOVVS1hI4NS07oJ/CgbnMuve0T5P25XrgrC/NaUjYKPUXMt5qcyJvfOutwyDcTNP3v0n9SG/FD7W+a6QS+ziM/sfwamFLLrrXtN42BnwLlgNPGv+47HRipHPP7N8ySb7l7dwlp6bwD/0YZ8eZ4gtxE+veb+iuLlkZLNCk+hWtu6qTapE+R0Xs8g6498/uhJcUbdNG/+SsseXgc5gPmEBUkacrSMjo9JPVy1rHT1p9OyDnt1ya3+xq5ucit8AGNwt1fbCG0eyACGx3x+TfcnD/hhB622wMNhFwbbaO8QSSvLlJdNXF84Qqr2l2tUF14MDAUYDmiLNKH92q5IqjOyYoX6psBQ5E8Dhsemy0xBqJhBF7Ct+udc71EBXfC6s+bMrXWOiNftzYd1U5pfeCYIJDxAWnqusG/jurdiXUh+hI7Nb8Xeb+bG1+FGeN0i423L2ungCT4E0oiR5ForzPWZR1QlsFgFchGA7lByLyz3VrRgbk0dZGz/bepLEWLpDJ7p42MZIjNHeXOj16qPAa5epbKqMAAJ6JX9N6vNKYcSbJGFXonYUlQhZPIpVZdJYxm5FA19BXO6EQ+ZLXP7TaEoS2ltdLfxb5MgEGS39zrj4uHvQxk0HhkGEckzJup/e3QR+St7DxF1MMzSEN/BDtO0RdjNdW+C0ekYJgAIYhxE3q37cESgbv1skz4vK8BKTp4xzEoTR1juOYXazHexE0bzibq48aO9JcD6fPtRhgposnKo3uQQA+fDcyx3ySIsDHyTv2U6u8Wgf9AMV1x+lAl8Th+mDEaxZTgS9KqISX8Z1cfanyyUjXVSWZNVndRZj7d9IS1B/096yn7bFdQotQkmc59Ki621u0/1PB/fpECHARkF7od/514lmHKDcMzErZ3R6HNPG4A3hs X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 10cc13a0-4db7-49af-343a-08db7d3cd057 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:15.1936 (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: j1M3OHX/sgC0gkCRqv17zzAPykNohsfL1dsf+mkA44ds1G6zbW8tGsjEwiMjHopxou7yV/LG5H8f5sqNnyepnA== 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770576603510422212?= X-GMAIL-MSGID: =?utf-8?q?1770576603510422212?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li Acked-by: Xu Yilun --- drivers/fpga/socfpga.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/fpga/socfpga.c b/drivers/fpga/socfpga.c index 7e0741f99696..723ea0ad3f09 100644 --- a/drivers/fpga/socfpga.c +++ b/drivers/fpga/socfpga.c @@ -545,20 +545,17 @@ static int socfpga_fpga_probe(struct platform_device *pdev) struct device *dev = &pdev->dev; struct socfpga_fpga_priv *priv; struct fpga_manager *mgr; - struct resource *res; int ret; priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL); if (!priv) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->fpga_base_addr = devm_ioremap_resource(dev, res); + priv->fpga_base_addr = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->fpga_base_addr)) return PTR_ERR(priv->fpga_base_addr); - res = platform_get_resource(pdev, IORESOURCE_MEM, 1); - priv->fpga_data_addr = devm_ioremap_resource(dev, res); + priv->fpga_data_addr = devm_platform_ioremap_resource(pdev, 1); if (IS_ERR(priv->fpga_data_addr)) return PTR_ERR(priv->fpga_data_addr); From patchwork Wed Jul 5 09:46:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116056 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1763318vqx; Wed, 5 Jul 2023 03:22:01 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5/FVWrg2PNRGV2fwE4iI8aDANPmu41XuybM3lexGaE9DwGvBl33FDzcJmJTKbnshCpbcPn X-Received: by 2002:a05:6871:4146:b0:1aa:192e:9f35 with SMTP id lb6-20020a056871414600b001aa192e9f35mr16845592oab.26.1688552521183; Wed, 05 Jul 2023 03:22:01 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688552521; cv=pass; d=google.com; s=arc-20160816; b=UMIRnwgIG5rt8Xr2v2T6Ky6XzitLU/MoHISCuWucQpET5d4zc4ccOVM38m1laij3yY PSzQxJ85Vi14+DZ3S+9ue+cBYdtwivSCS5rsteARPZkhyVJ9oOoTfe+ES8xIq/UBMYDt blc0un3BRGC+r7Nn+Pu+DAhw29+5YCjIivlOY0ZgmYg3Ufb5I+gJsxlXpzSu47t9jLXW MBXON0J5nbJe3yqd6cw0WxtmB3qjuhSBBrbMvqys0AL4Io6qvVKdTtuyk+27WlCCcMjX g05pntU+ANDliKUXs4a9k0BlBuFlJyD+a4dF/UJSxRe+EH1H9ap70JTXV4UQ5SjlkUna f7Aw== 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=GyPX6jX1plieiooev6Icr9crN/8MKZaa36xXoB1z/2A=; fh=N7Ju/3mTnC5+r1DBRSHufx1VkyaAiNL4MqQnCv5D4WE=; b=0fGZCuKPxqA3+NILM0yFPhsEqSzTJnsWJC06NLmjaQydHAJAIpsq/V62S9fmaOTut+ GL16aTJWpFRCcUiCiN4neDlXc4i/qmq9NXPW6oQE4Tjw5WIn0nFpvsiGaMbcXRLA5nmE 4Srdbuerhwr51vImFFtopMNdrDABNqBTBTJgEuk6GO/Yj6ZFjpIZFikx9bMUZGuZQEHk Nx7R16ArFU5LW+ebNQNkDYMax4UijCoaG4N1QwQI6tRGWVQk1bX8Vy8oONTs+G8GwiYb vaFBCOU2q8l4R+lcSgRAH2w4bOsrmOthyOASspljj11cDH3ezf4Y79N6S/kZ75/t/ysh Hckg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b="GLJOc/lI"; 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 ay24-20020a17090b031800b002630cae4f47si1308660pjb.66.2023.07.05.03.21.45; Wed, 05 Jul 2023 03:22:01 -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="GLJOc/lI"; 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 S232102AbjGEJt0 (ORCPT + 99 others); Wed, 5 Jul 2023 05:49:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58342 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232132AbjGEJrb (ORCPT ); Wed, 5 Jul 2023 05:47:31 -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 37CC319BD; Wed, 5 Jul 2023 02:47:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XPW5YYxjbZHx8XVhPdeORq3bPdE0SDIHxJzQeRc9/nTK/Q73Toe76oDMf9WucqSloOBbOBCWmp2aJC6I2ZWs79RNJnZT+Zmu3vJ/oyCaosPegNNtI2XdsHy5MEGpNm6XMzF+WaO6b4qcd9WsguRqQ1ehN4zG0Ojwm830EzUmFgHbGYr4HMoLMF32178rqEPAinb2kVWw0Wy+8QsDzQEIqsPRKY0XVtseEIKkvQreb+Rm1ooiFpBmSl5v9KAN0ww6mGj0vJJ/ZkO+R/Lqe1a/nJhgS2uWNZngqAT9ZXTi0GbX5YHte/DVkcwU3vWk0dFcmj0AlpcLJJn4BcvoO9q4Xw== 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=GyPX6jX1plieiooev6Icr9crN/8MKZaa36xXoB1z/2A=; b=mF1wlOtgfyYsNpiJdQrzdU59Kdjm4rSan9vDDZx8+qMPiVH4mcxViLMOfuPQg+HAjTMVwJw+Bb515osGQFYIDCbT6tp8+wOhMUi2ioiTgTPfD7qBYTOJDLRrmcVxqrhxcAX9Ajv2sRn+cmrCpShzLu7+wGJmm5KkpiARSqbLe5KBzmgjShWPu0I0m6n7T4qJBR8/bUi25lW0FRq0IB/sJjC52xuztQhfSqS6nhDZo5EILniOHOOpuCjtw6/1M4CfPy7h8d2pIH3RDfJ3oSq8FijmP6yJnyBVHeegbHVhwyHMaMaQBe9XmMr+P4RXxrGB36fQ378/5A0tY35DDf8UIg== 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=GyPX6jX1plieiooev6Icr9crN/8MKZaa36xXoB1z/2A=; b=GLJOc/lIAH5aFpVFyTMNwiinO4oyDk5DVCOCPztWRIGpWnWY/nipGbjFSMhTE+g8dRSHw8LrN+QiGZfq4eqi3lFDqiZsDKwOXyT5ihTOBu3p/XT/mTXt5Dv+MWb+TGMcmE+8waumYZDHXTZY8NipbNqbqFTMr1bv5YhIFnpa86PCpZ5M+/qps+8cBmQMTvsonEnrB0kLktqOJIGnDh71g0HGIPR+jsg3+Ef0epVf6dl5FvthPR7PHoSH+3oeWQYoJkMqC1TUUCEMEx8K1NkcO44VRpgm1KeNoJxbZh1V7mTH43dUXwhW89SCvBK6xqSAeRuWKN0D41TWrc7qIU3jZA== 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:17 +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:17 +0000 From: Yangtao Li To: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix Cc: Yangtao Li , linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 7/8] fpga: fpga-mgr: ts73xx: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:54 +0800 Message-Id: <20230705094655.44753-7-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> 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: 852dc03b-bd77-4ec8-a314-08db7d3cd177 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: CfrP4r44wY3HwWe5RdQCUKaT3HW6OiAHccdtau/WEI2CSRsm9ei1ZrLM2skU9RZvauyZI/5nmFhbOUODRxP5f365JMtAFjOvQYO9irGW2Pca+23SZvACNccqdwCQVxOdw6AUw26H8MJsYSoxdgx+64auonL9yKeJ6CG3xXJ1nft+5awfLBAt4RrEMHSxDNtxic/f/yyJiWN0p1NU/UTXtDuFGvvYncRaHqb5xvTtA2Uubc435epcdBWZrR+1GEc7/cuupD78imsrD+x7AvE24oV1bPntj7TxnDafDX2LVBz0+zMmD+C5OZYxb2jJa9DfxDoRSk4IHc7RO2hN6fp47CrzvmeoIdQy3JHFQ9SkGu/HivUHMQgpRRDbYYApBrchk59W9AQZQziLetfat46LBGJkOitB1huXEqWBx8xxzcgcpbSR1OP5EJEN+K26umnHAX5rytpO39+krtf8adsd2u7uONOu+3c/q7OEtaDe/wlqyMtO1cr8O8IeTTLsJWSayFNs+wXjI5J3b4vgHY9aHUxwCBzrJBhybezHqjYQ2p6SztnWYbM97L+2rSlIA4JIEB5MF0tMtDe44YDqjj9a2BXwoR6SOgkMn/UlnTTOUnFSheNoPbxt6fXNRY90/wVv 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)(4744005)(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: 5juN/ZinfmldglX8IUqvKL1zH2BsBA2p67Hwg+3X9BbAd/HUBdTz1lKLI+Dw+7J2SooOZdPwauNkgSTwphuHeIoI6TZHq4q+E6T3ZsPFLVnuTy0K2pHtO4nS1NhZLMaQciuEunA9W4SR/ybvI5uMZpEvje9D14ARmS9Nk6DanozBksOAsK1Q+DKUUi/L24SUuXha4AuePTka0HV7rRtoGdkqxPFMkjhCIOWKOZDD8KPAuxyvmTqEpywAHAo7yGxk478ZRJp4LT/zmn8dBxBljtwQqJoZmagncZ/2vAN6PyTHwWI14Q3RkcO//hDNwRTvZqGkqon+L4u5L5pnDtszghMWUR1k6B9+f+od0flaMF6YnnT9cjjSl/Uue8ndp5VXRbVfAupoM4vbXX6R5BGgONypDj3MFr43wSPy4vntqHqUBdxjJVJP4GANPdqYmbEWDU3clQmR1CgC8cOMmsckskaItwIIq6QgVDxrme5lcsuFHFuEtA9j2x+BfQOwVbXbYFlbFnv6zull2qA5Y65nk7aIsC22ybDcaxQBUXdQz6jwdxf7ijMMWybc42nTgJAJNpsTv8FHU8qaY0BkLuyXGBkOMtdKQRxDhp+VHzy83Mo7PejzPIp9NDa781lLVwBZcaDQiIZcRStA6ltQZNtGAyU2Uc1baGP/AKrXOQsSugw9XBw3Mwtqq9HPzuh2bBDlskTNTgPcUZWBskjIN7k/F17qYOVs+ckbllIrplizsXB8t3Ca0/IdlassWEWg4M4N/uRcnAeypbq2EDCn3km0ZAqxnJg13eDtHjFo9LALXuAgP4kPxgUcx9YVAT3i1ic5faO92NrW2WYAizUb8+od/wsmk1Ng/mCn5guI19DCOi6vNFUUxNulBMJOsHCkIEZijw4iQWytQRV65aq9hov6jhuXwISRWy0rOBGYp5BM6wS+Vbr2Mtp1qzI1E27ykLWAlyXLCcs7MQBBKhfF/NR0OZoydppiSNznVGVhLJ7KN8VSkkguyEZc+aXbelZVL6ASvelUUacDckEI/YKO66tS188lQIcFdCfK3Ozt1t4WKnSTzKKwxbjcIitDaOCJL/FqUNiF1CxP6q6UB914Ot4qlmvskKEQSfTBOK1u8qqbh+Bb2NkT8TzI3f8jgc0nEgZejSKeJE/4KkXMSmSRi2zng4Ei/nIXakTm0Fpl4ImUEpAUuVDAtpA5l3sqpzdpTUV/ZZaHWlk1LLEwMroZnm5o87do1INO+e4sBlVrLEYcVYEBOV8OJS2gEIXQ7nwWtJORacsFTVLrSBOJRmOne0Vgd0zixRx2FZxHocUJgxxz/uRy4ZddznwZDRU8QbZWm5f9s205skNEbsxtNEEEuOQjRt/ZQqKK618XK5UtefbBjW2ErhGXNFfbDipyT9d8an9xLC7eEGEboXyptAlNO4equyaa1a60LCJgPqUO5TwUblCKt5colf8GI/LHbOv/ZV0Qhr/n+cAEb3rPIe+Ag72g9nLnS1A3wEiOu+IlAHd5bRrDwBlJJ78ymLlBw723U9PXsPUwPHOCGZW6kcjQz7Elo3DracNFybOJeSnkEnXkU27gSR4e5PrmRDO9SVatnB2z X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 852dc03b-bd77-4ec8-a314-08db7d3cd177 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:17.0831 (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: tYW00Al25bdXWRcDUFIFM20XkXyIYR4iOCDBOKjU7zSY3LF1//zvTd/ldUlzunC5bJ186WVPzmAp7LU39W/q4w== 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770575648348376945?= X-GMAIL-MSGID: =?utf-8?q?1770575648348376945?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li Acked-by: Xu Yilun --- drivers/fpga/ts73xx-fpga.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/fpga/ts73xx-fpga.c b/drivers/fpga/ts73xx-fpga.c index 8e6e9c840d9d..4e1d2a4d3df4 100644 --- a/drivers/fpga/ts73xx-fpga.c +++ b/drivers/fpga/ts73xx-fpga.c @@ -103,7 +103,6 @@ static int ts73xx_fpga_probe(struct platform_device *pdev) struct device *kdev = &pdev->dev; struct ts73xx_fpga_priv *priv; struct fpga_manager *mgr; - struct resource *res; priv = devm_kzalloc(kdev, sizeof(*priv), GFP_KERNEL); if (!priv) @@ -111,8 +110,7 @@ static int ts73xx_fpga_probe(struct platform_device *pdev) priv->dev = kdev; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->io_base = devm_ioremap_resource(kdev, res); + priv->io_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->io_base)) return PTR_ERR(priv->io_base); From patchwork Wed Jul 5 09:46:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 116052 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp1759113vqx; Wed, 5 Jul 2023 03:13:15 -0700 (PDT) X-Google-Smtp-Source: APBJJlGe7UQyIWMV/cYmRthIiFhNM+IUKMgObl7LK/xFACpmWve/hky68YkBvVoLYEWnKUa6jPYs X-Received: by 2002:a05:6a20:6a22:b0:12e:626a:7455 with SMTP id p34-20020a056a206a2200b0012e626a7455mr12509295pzk.58.1688551995676; Wed, 05 Jul 2023 03:13:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688551995; cv=pass; d=google.com; s=arc-20160816; b=Hmth7aivhuPNffSEj/5Vg5jUnaZHINNgsemW9t61k8EDXZ0b9ekL/4fI1IoH6nWERS st1B2VbUxVc/xP81DYKFkcu11s9A+sdqS8qHfRzJlFf9fFnIVrd+FtGoEfmA10Kl3I4r FTlkXBFbVrcozqm7IHq5Q5skVllb9x7aSqCgRDZXNUro5fX1hNf+784lkIhLQOKbtzxj 5IbX1oxa3hd1HdF+Phfk2tHU+chXTKWH481odpOaJlf3wPkAlbxtXDtjZTHouN/HRR+n /eOCAPpDfa+cCDN4p+hPqUhO+XA6IqS5z0HV04SHq0SX6GpZnPiaCn6LZYBJWVnz3Ry/ cd9w== 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=ZjOm6UAG4W2jD5ACWQU6e6juSINzxVbwn97et2nkctI=; fh=1holnKwvIHq9l/N4ifIzMuhZt0uEvGuqYJ6SHouv2HM=; b=HmPquJfudvHyywSnidoNZd9vVM7LGjr2cMGga2Jj9Gbf9dzlDZ7+rR9aCJQ0pLbm3H XWbs5gW/iKAR/y6tza6GpuZOGrqA5OkS+Q8XDLmWOpwD5EFhtnwJcJwG6Qsz1iiFMeX+ 5qPlge8UeACQVS0LGqsZawmiJtIvqnubjlUquE5ZLyaqLJ/JYCFOTzoDNek+k9ONAc3P zhBqA0KypfAmlDI8grraxW7puuc1a7Tuim0gAC+YrzjSTk7xyCFtBY4sHQDbz5LjCy7G OcBe2dN1ulZJPeoFOldG8YzmCoYUkRBq95JIblelwqvHSgFG+TbQu81MS6wtVOJSfyIp WdSg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=BSnzHxV9; 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 p17-20020a170902ead100b001b04741042csi17590861pld.93.2023.07.05.03.13.02; Wed, 05 Jul 2023 03:13:15 -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=BSnzHxV9; 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 S229812AbjGEJtQ (ORCPT + 99 others); Wed, 5 Jul 2023 05:49:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58628 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232317AbjGEJrr (ORCPT ); Wed, 5 Jul 2023 05:47:47 -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 46CBD1FD3; Wed, 5 Jul 2023 02:47:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dLy/abkUOrkNlaB/k/hgcrMeQqUpQsM68MveAGGE1LUOImBCQ2IMMILRMHt2QxTdUyhrxpcTyCg2gVmHbouDFNq40uiXdAS3wWbSEM7uCDX2BjIaYPbOLFkGuI54OTbnqB2JufVYp4ovrobOYQZ738KZEEBOsYxDwq4/eHtTqtlf8HeDIlu2qHh18Qd3FJcTD8RY/WgMd8UTsGnYBJ4cyvNCywjTcEPFCFqZbpoPGrbeXzsNH8KFyF79GeFyREav6RclylDjmmtfv5/6ncelSIeiCcpD+ZmU42NiPrisH2K6oXyZz13mJxSUJDT8tnFGvUFV3N0USQ6lRba4nrWXSQ== 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=ZjOm6UAG4W2jD5ACWQU6e6juSINzxVbwn97et2nkctI=; b=OhLahqgIha3dMuXYe3GCf+fNj43tt3Shatbn5num1Gd/o7bjlTz9GtdLExsB5kDc/WZvJAb65ScGbVpaRM8aPb59zN0OSME2FVIQuRzUvU5C4+DE5+7pZx1HYZ/stjOguPgnK9lNeHfYPrareX3JjH/3ezpP9cRnxAKIXMk4z0EMIgWAtCBFI70YjtOsf88itTraUaxROY8ZD+sDv/QokA5aDq3LfARFSJ1YE2/e2SSUu5cevO+mVEmhVmLrlVpQ1mXHQUeO2j4z2xNWS+FaoZOglB2VWFglXn3w0KxyBooTstnLB3vI5nlyrScgCffAKYgcM8MUCiC9VmkO8mrfMg== 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=ZjOm6UAG4W2jD5ACWQU6e6juSINzxVbwn97et2nkctI=; b=BSnzHxV9p1LzYiI8IrUqmQipF1pRkO23rdtLe/8tVC/N8Mjf/g2kvwlc1E4DWV8BqGfKbypIH49jr5XJ/AyWBWW5Sm6Id6fi2F0Oo+t6+aA+6WWw3PRI0HGB+ELDrDUN+QC5jn22Uxj7hcqL9WRnGExCByHIZrhXLHdBnTqAigg7/SAr8R2UHpzpibm3wstLhpaGRXotyZTrSC6+ZZEGBhslYrbGI3UXrMXGpGj4nJXRjMsAI4WIoDjT3XzqHasP0LaoU7Hexb0THB2AL7XdQHHn0DS/okrq3kgXS+bsZBbxI9aJJsq1H/cQ8192kwndoFIEGOF2qAxFsfkgfD4Z/Q== 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:19 +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:19 +0000 From: Yangtao Li To: Moritz Fischer , Wu Hao , Xu Yilun , Tom Rix , Michal Simek Cc: Yangtao Li , linux-fpga@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 8/8] fpga: zynq-fpga: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:46:55 +0800 Message-Id: <20230705094655.44753-8-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> 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: 23b25d1b-3efa-46af-e538-08db7d3cd2ce X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: oqu5Bb7J9kuNH49tDirhm39Ay58Dz6gtO+PobEio3Kf4sc0HGiXlqWY4Z+X/hhdQSOiURV1Vvexcs4vE5ookCsCS8N2yaRS4xS3/do+ntjg1Y0l+n7uA/Vj+wAKaj8iSfgWfYFKoebi40WYgPI4TUzckQz6pWU7E2b/yQKG2CyHsz9mlCaHNYIhxprVWmsJJfkg7rhcCKipk++rnd/Ex38zBOQtxDPDwR5HR5SLWQNt/yOw+GW4kKl98RGB8qgTz53ltpYK1q/CY4fTPiRL9d8aJkjRJbES8kWuUCYf/99tVYaKBO15QMZgUkgxQ4ZP5Vg0NHs1QIfxbXJHdZ3VUr8SZMLJmpcibnkBs4AlrY52dLOgdO8rSSyw6RGm+kMeVWFbtPtUL8H4DJ2QuHUK6drkEEF93GE6zhDxxZWHEgWpXJ/G7+57XyqJFv8jpaBPxDtxQAEWJdvnXmoFG5UCBFjoP6JimMo/FIR72OLRP+hTFaS5a2MT4KS4/s0rj/2nQ6q1FfKUGcW9aOeo0+YxeruORu+TWEH2ltfyxFCimfq63mcJikchO/M5VOesItebuZBQwlPiet6uMQlF8xGxAlQTJRaosO1TDjNCL1kBncupDiruK2cOhJ7U2nT2ZZsN4 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)(4744005)(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: CjsGwhFSKNfwkkGbGFMcml4gCxzQUF6KlmQJK6isLZmL1md0DVH/O+3jlPiKg3PfGZLWT3gL1EmCYSl3HOUKocUIMqZZolCl/F3yfkRGz+7XmBdN9ZY8jNNOHsYQFRS7dQ1fiLuO8CS9LRII3JR1XPILV7oTc7U7KbzTvXI5esme3q+uGX3DjgzNdsvrIiqe3MX7YdvzEqBRZRHTWDBb7g07yBmXc/xJCu5E4pe2aENssUKu4pPB97qAvA40EisPsJXafohGuXS2aRIHanxP538dzmEzMH36fqc6PlvR3aASCSuUqtFm9ql19TjVJ4AxKt1mHnQFqheaCMm4hzX1o2hB1nIRP/fMsnNRPe3e/2bDbtFlkIlW0SVhIzZTxt14niQsfsNF8To8rvGBTlDkjP6WT0egPqQBoZ6H6g82bxJJ8iEnfv3pR5E5dymNSEOUy9WrpSMaG61iAluH17uCFOwZMYpq0G5hrP9E89nhO7hZboLCIvlfnIHETdSVQQG7tlss6hwhKHDAyO0ch6TdNawKWBjRso6v8iah6INQZ9BQvwVsjP5Z0py5xnZ5O2QTSYjn0l/915iOEkORTOyT63Nd0gcNkQnmFBth4UBQawykMuQSggzPn/o0RWP3naRgOBZLL6pWwJuRO+sk/85WnPVZrkKYEzJclPelv4kDfr4UWU9JWLnfcEbYMnzA04omUnAJJtArNW6mtcrIsd7CL5lA3LxCsRrN912TYkDofklT9n+Jio8Fbel3GOtO8FA28kqUJGECE5YGJ+iriXF05VMXhaPMTVmsxr4HQ8mH3TAK1MiJ+H6s4gHfO3Ogph3fLzcZCfO0vUsVKAXv3XAUwzwyRaqpsmz85Yx+mCQgHy0JRX3pdpjn4UvyW1sAvLpav2zI/YizovNcFDjLL2TpbvlLrI5IMDsEh4Lw93TSfGbITBAwY2YOwcABw9CQQBzlYpjbOAW73/EPzDpuSCBIL1yGgrD1n1BXycglRbEG+D78GBeyLdgCCDlRs9AuKQ68JDWG1pWnAP2hilzBcDbKZ8FaLZZ+dtZipTRZL9rAp51/3aXApPajOwmYsA+VvbMRV0pa1E8fjATRWMFpocIuhL6u0ANPnTPehJknBKN7HZyZV98cEP6t2vItmBzaVNoaQtBlz/KXd88wa05lBl6k5BR+8n4Ry7SOARowEJcdaLa0ZoHjVuqMvqebPPDJBpAQtyBGok6i7sPhXjYdnSSk0ql6qD7/O3csirzM4dK6qb1+Zia5iQ1ThTW5ELgD9+p0QnXVjbiYA1VdqZnl5TQl/96m31cFYoi43p9cq/CP7OwDBXeeYOYNMuKa6EEjpYbYDiMBKxjkmvEp5HuJ2rW9CzZ+MDWC3Xe0LmNT7bFvZ2n/pLEpaPomVPnm1u8JZ3UAhBgqrCyqWORhduyZofBxUaPaVyUKnY+wInyYjSQWXwVdLZwxbd1E8H3CC9vfVivBeO6HmVmOROqpn/NQXCdxgkbrlxbVhHLSM5iXKeQ2YKuwBE/ULjoVO/HLOmRGyqL4Vrfm7zNoZRtBOzr4MtkbRr3WyfoloUAJSUmA95l3Pm1xlSfY5RLrhkGo3lPLT1Dg X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 23b25d1b-3efa-46af-e538-08db7d3cd2ce 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:19.3292 (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: i8UexYpLTS1QQKFxOYCJlG/YtJU3o8s1VM06iGPEBq4L/j9Q6xxxYY1vgCCs4YYyHyDwgtyIhDYjIlEnhG490g== 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770575097374283277?= X-GMAIL-MSGID: =?utf-8?q?1770575097374283277?= Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li Acked-by: Michal Simek Acked-by: Xu Yilun --- drivers/fpga/zynq-fpga.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/fpga/zynq-fpga.c b/drivers/fpga/zynq-fpga.c index f8214cae9b6e..96611d424a10 100644 --- a/drivers/fpga/zynq-fpga.c +++ b/drivers/fpga/zynq-fpga.c @@ -555,7 +555,6 @@ static int zynq_fpga_probe(struct platform_device *pdev) struct device *dev = &pdev->dev; struct zynq_fpga_priv *priv; struct fpga_manager *mgr; - struct resource *res; int err; priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL); @@ -563,8 +562,7 @@ static int zynq_fpga_probe(struct platform_device *pdev) return -ENOMEM; spin_lock_init(&priv->dma_lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->io_base = devm_ioremap_resource(dev, res); + priv->io_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->io_base)) return PTR_ERR(priv->io_base);