Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp34784354rwd; Sun, 9 Jul 2023 20:34:38 -0700 (PDT) X-Google-Smtp-Source: APBJJlHH1LXf63cTBPN2Op85MQZuDbtXxWxv4PVv3a/PBrQEFr8RkJGNINGgv/lcTposnNGRanu6 X-Received: by 2002:a05:6a20:3cac:b0:130:835b:e260 with SMTP id b44-20020a056a203cac00b00130835be260mr9377644pzj.52.1688960078245; Sun, 09 Jul 2023 20:34:38 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688960078; cv=pass; d=google.com; s=arc-20160816; b=YJABqnYE1vJsRcYMQHbXEGEmyi883xOXlpEmkNA4W6qpY48oXaegXmQPpZZUhiwtKk iwN0WDzdyv9KhBGLU09Z4tYYF5sJA5DWy3LHA0jhY8azVem4z/I+LZa6jrskYmGYaUHj q11CUIYlpZmvXdqVfC9NlBDtsTe+zaQycB4aEc8/FLJ/rq7wuWnfeLaFRKDAz8o3ahuN OCmqQNjWlgHAD+8TgyQ6I+DNbaqr7ZK6bXw9A64W1TrUgPoMsJlDg8PgQP45zHcybZGf amyQfGpOLpEpxsz8D7mN3tDhN3BhqfMwCb1ugNO/Z6R09FzK565X8+tDr5GZmvAdGuqo Gkvg== 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=XPh7w2tfUcUCDzFXMlvzWNOdVB0uj8dkWp6h+wAiGRI=; fh=OkhKJqwgmok9Uu1AW5HLWSzylSfBluM76Bb81dugc3E=; b=p/ww7Bo6iaPkvEGj5HgL3v2Z417V79cxGLSpYXRY10EiOHEhw3Qmu43q2eH0PnlcSg RthxshdRMtoqEld/sLu4yZ5/NgZnquCijSt3JWI3ms1ZuRBhYyQXMQoM87Qj11bO+ZLQ fYV1jOK99/UTCsmlVt5T0PVOcCgDBUgKhRY17CuE5cDfbGLcaqw04y4eTQhU47dVo9Eb EZjGCmrdfLpkHS0OYvgniHLD8Qzp+fCXPS2zbIEXPUCxQ774ijfsIOBGZRNnLsMSaOS7 VpmcqQSx6Aov45N7OmAvDM8HoQp7Q77BLT67cT1+fMwxQmIv5roclvN2pw13CyOVh8hs SYwA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=W5262dQp; arc=pass (i=1 spf=pass spfdomain=vivo.com dkim=pass dkdomain=vivo.com dmarc=pass fromdomain=vivo.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=vivo.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x4-20020a170902b40400b001b809828a8fsi7843213plr.366.2023.07.09.20.34.26; Sun, 09 Jul 2023 20:34:38 -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=W5262dQp; 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 S230240AbjGJDZE (ORCPT + 99 others); Sun, 9 Jul 2023 23:25:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57324 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230057AbjGJDYu (ORCPT ); Sun, 9 Jul 2023 23:24:50 -0400 Received: from APC01-TYZ-obe.outbound.protection.outlook.com (mail-tyzapc01on2116.outbound.protection.outlook.com [40.107.117.116]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4843D18C for ; Sun, 9 Jul 2023 20:24:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ETAm4LhStVE1uLwhQY9Re4G6Qc+uXClXanZQvJFmbjoKHv85e9bcyZylYWUC1HlBJQ08dab1JUhCgjXKK8IQudz7j0Fwgj5Gm8Z8+bfY0+8aiq4jJ7wZtD3eLh2dw6wsZeH2PkN62TygBbOYqOVtIqeOplKjzidSSOboKZ67RMeQm8atFk8w26J63L+JyTTEnY7fH3stjShHm2aVMVLXma/YHnkL10A0+macR4CaUqoGvicY9/WCD2Zp4hK9tPa/RpFzAEbGWNXIyAL605zBnXsxUxGGV8rt3CINLMc+2oBeTDQ7PCyyikr7E/1OpyVG8rgy1oqVlLrhxY2nJ0LeBw== 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=XPh7w2tfUcUCDzFXMlvzWNOdVB0uj8dkWp6h+wAiGRI=; b=AFE2KcZ/ixZet39xiUejnOe85tHFakY8rQQeNK3NMg5NYlOqAmWQNqQGRdKzuh/49LDertw2uTCyl6T7wTw1dR7x5Fox6sLzQj+SjI2AP1Jo3bgbi88TrQhRMc4sATZZIFB9po+LKqCT793c1JbXxp5unRNNCYz9ck0uU28U2ZTNiT0qO5neK4Kg/PSTkgECz1cUp6oDyxUoAbNLCSf8BoBd+2YLyXHlGV2FmRIQcJ0/3jXvPJMaJpeM5HSnzsXSbeNMFU37s7xXAXM1aQOeQUSFIWay0VaR9jAqHsBSOW2NyzLFl0FTvidm+z9rA6lfFTWeSXoCqQHrBKOkwHcmUA== 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=XPh7w2tfUcUCDzFXMlvzWNOdVB0uj8dkWp6h+wAiGRI=; b=W5262dQpMFc2426gBEnwK8Nfal8I0j8e76l1cqeid4QPLZURTE1rdM4DMIxpkWDQogTtyEWQmIe40RKenNBjTw4bg5+Fw7rv01QPXrbolhDtFB/R4gk5LHP/bZ5ds9lcthAg0CiZtcf7+/FLrWdH9JwZxTbgPGkCO1J1dcrFSMszeJ2nCycnVqMhj5cu2b3hlNPkKhNZYI8IDqDXCrcrtHq4tBT9A6kCIts9depPjJenggzLUXgV0IRj/I0jQJxoxFHtmZhxqJ2WfhoZodksIBLYILWpkDgpEgTNL68r10iL0ff+a34eDekjX84Yhw5drxAlRpd/uGW92ZVX4OIkwA== 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 TYSPR06MB6472.apcprd06.prod.outlook.com (2603:1096:400:47b::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6565.30; Mon, 10 Jul 2023 03:24:27 +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.028; Mon, 10 Jul 2023 03:24:26 +0000 From: Yangtao Li To: Philipp Zabel , David Airlie , Daniel Vetter Cc: Yangtao Li , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 08/19] gpu: ipu-v3: prg: Convert to devm_platform_ioremap_resource() Date: Mon, 10 Jul 2023 11:23:44 +0800 Message-Id: <20230710032355.72914-8-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230710032355.72914-1-frank.li@vivo.com> References: <20230710032355.72914-1-frank.li@vivo.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SGXP274CA0020.SGPP274.PROD.OUTLOOK.COM (2603:1096:4:b8::32) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|TYSPR06MB6472:EE_ X-MS-Office365-Filtering-Correlation-Id: 0e0984fe-583d-4599-8764-08db80f52a25 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: kYBw994qVInCgLQpzicQqwAG0FxBmAqaFjI1ikujnlhyZ1k6BeIifyD/CR2z4qx7ITbOBgIV1Sqd60cZX/VOHgNzPp1yiJKfV+tlSqn2yeEA0M6pG4PLBJTvo5Tlfp3oEvvdk+FIotiD/MlbFg17mKPQkge5m0slenCSqz9ETkppXsaXqJnfa4q0ZmNySHFQhulZ4tS1sEB+V/S8ept9UwKnwLLrsxcBkoAFfh602R0/lim8LZX9IJWffosz4MVKG/9UL0q9M0nRUfCC2RioI6Rb3/jy8WPkEMeQQfsMBRdlcslHm9JCuVT49aPDYfqYZ0CNZ/BU/g9GHgjlJsAsK0ZFGp9iCUzc+MhZw2vYyXzChANBCqwlfjjkoPBqlhr+exvrZjW39LnUillURK/24NlWrHihzJ63WLWsj9c0XSI3F6p4DFwRT+hNdrJu7C/txbDVN2zSCqc5Cv4Jo4NSnSS4MNJLCJX3mKXIRXss7wiwQpz71k3x3fsIqpc/HFIv7IWLvQKAo0BSlognokQmUx+IAu+AgJfx/4kXPhcSg7TLXTAwzcsU+cLhnMBhdADgBLHL9SHjA5YYABHEj2D3cA2bzEsvil3PbsDSmSDIiSo5VLd2CzQdHmdwCdJ/tZix 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)(39860400002)(376002)(346002)(136003)(396003)(451199021)(186003)(6506007)(26005)(1076003)(2616005)(6512007)(83380400001)(41300700001)(4326008)(2906002)(66556008)(316002)(5660300002)(8676002)(8936002)(66476007)(478600001)(66946007)(6486002)(52116002)(6666004)(110136005)(36756003)(86362001)(38100700002)(38350700002);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?gdCwJHbtFe+gDiL4PvoEBhqDCndITvsSTc5ky4LLlx4xBvTuKlnuPITdHg2t?= =?us-ascii?Q?cWWRO8tO+ELX9ut8Qg7dgm48ET/A/N9iP/B8f29t9hZ2C/DMpRPgXhsod9Ms?= =?us-ascii?Q?JekvlYnmIQcsdorv+F6/qVfur0lNJrm3iJf2d3ZvN9WFGUfPSvbwYn1dMDqp?= =?us-ascii?Q?Cr2r5hF8GuKpH7+himKrFDyBqjZGeudquGqtLnwIkdTezYp0tIOgj+S/mPkZ?= =?us-ascii?Q?dTCQF9DU/LWUCPAjvdZc390qsJFVAfIH6wvxeoSrIk3TGa3kLg4NDOj2y/6q?= =?us-ascii?Q?OwiM8dAvt86AR4p/hWRWqQs7AnRHxkaVFBzvEFJ8Vn6PSkzw6OkpKU5NjWhw?= =?us-ascii?Q?znOk7kTjx5UPO60vSk0nlUpgMouNbcT6pZNCwbkCPc5pAq7xzRN1wr0vL5Bu?= =?us-ascii?Q?BZ5DFq2DmsW3jzgHlz0XCAez+I0dfZztZsWhLkJHtqTyJGcdQ8zNut2zi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6VfuBG0rKP3uxPmlcrX7F648/LhM?= =?us-ascii?Q?O4J0x1JxGDOF8T2UMKjjH7/hzk9Yo39jCeyS2ru2fbP/+cAcLkBRzCH+T1BZ?= =?us-ascii?Q?pss+W+720LBpI5Yh2iy+4AQho/TlQEmccpTTil556uDCxLr6JA523P1+jDZf?= =?us-ascii?Q?UPXuN+YKLH6xLtmiRQNDU9wDkCmL//GmV+hjLpBh7FBDMix0OoHHdVgJim0x?= =?us-ascii?Q?5oelLVg6X5o3Nd8on5Al1DFurA3ZzFAXtvdy4n3E?= X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0e0984fe-583d-4599-8764-08db80f52a25 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Jul 2023 03:24:26.7680 (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: Qy8UlIspDyeliP/O2taJDrp1wx9NZB+piDRgyorAwlxSB0DSYSIfpiUuYGPYfL0MyZi1UjpWO8DZ+OC6sVwR4A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYSPR06MB6472 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_BLOCKED, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li Reviewed-by: Philipp Zabel --- drivers/gpu/ipu-v3/ipu-prg.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/gpu/ipu-v3/ipu-prg.c b/drivers/gpu/ipu-v3/ipu-prg.c index 196797c1b4b3..729605709955 100644 --- a/drivers/gpu/ipu-v3/ipu-prg.c +++ b/drivers/gpu/ipu-v3/ipu-prg.c @@ -358,7 +358,6 @@ EXPORT_SYMBOL_GPL(ipu_prg_channel_configure_pending); static int ipu_prg_probe(struct platform_device *pdev) { struct device *dev = &pdev->dev; - struct resource *res; struct ipu_prg *prg; u32 val; int i, ret; @@ -367,12 +366,10 @@ static int ipu_prg_probe(struct platform_device *pdev) if (!prg) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - prg->regs = devm_ioremap_resource(&pdev->dev, res); + prg->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(prg->regs)) return PTR_ERR(prg->regs); - prg->clk_ipg = devm_clk_get(dev, "ipg"); if (IS_ERR(prg->clk_ipg)) return PTR_ERR(prg->clk_ipg); -- 2.39.0