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/VmciIczikIRLe38MktjswYwzbbCdJ43z264YEngKBgyb5VQAeWPLnFBY4aIhosQHyAwZHygL6cytFJ4ohOZ4QAHqOB4EZf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g: 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);