Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp31551644rwd; Fri, 7 Jul 2023 00:37:50 -0700 (PDT) X-Google-Smtp-Source: APBJJlH0R26io3wp9p04dJRcJ7iGvVuI8ML4vJoMFIBkyubH969q2oIybMKGqvMUj80eHKjZI2M6 X-Received: by 2002:a17:903:1252:b0:1b5:561a:5c9a with SMTP id u18-20020a170903125200b001b5561a5c9amr4313250plh.39.1688715469708; Fri, 07 Jul 2023 00:37:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1688715469; cv=pass; d=google.com; s=arc-20160816; b=MxeHhRoEgkdYr/rCwOcUYfHb5MUWtLaNn/04w+EX5pWYUKvhGt+JOfJrmQV8KfqRlR PBPofaiVPbJKu2dETa9i5anz6HVDNLR+HwCnXT12Lhj3qoWmgKoAnZK/5D68FtIcxncN /Z3KnAuruScqJXgaJX+b1rOUQb/GIBIkVNvrGMwi+B5zdq++HqPaXL+MDG8h/K1LB7+Q dZNDsIewI3MiZWP+fybIe1DCy6VbkWhGlGSckAXrgUnf7ABM+X0eYQpRwXINTsAyfV4p vdhrLSdLLHXgySpDqP5jE9egvMnXCRPvM+KfMSVKniA3iIWjeSB1Ve0J7qWjFX2oWMBI rB6A== 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=449EzXD50MDqlapJVYQHXZbZyaDsBh6tefDqbEGmmWg=; fh=WTFhmzzhsO+5Q/8VFH9YUS+fINvQqtxHHn5A5T9J1z8=; b=0NaGpQhP3r9YRcINA5StzTcthi8qokmdt2FnbppTLQiWO+Sss882k01P2FM8sBLRnE DQs/TzyIAFIUXpJsmbBuPTqI5G8byIA0LVuTosG1opyHIfuEWQKadZNKuHj3l/xOO4k6 kZcQpH8Fp/VrKbvE9iXS/VV3aPTkgvLvt+WH3WLZcZycyQ7JfjYIREujgeQodePF13WX cV+MgEEA46CdpZPyTPD+WYErRv6pfE3NfYau2p/kHnHOMlBaD0x+FutZa3yWNYI3AL+p J19/t7W9fpKYetaj+LULSojYI2pWesY1FeV/savA59Ml3gR7bO3t/7/j3OqBO7ojl3PZ EwjA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=POJapzSI; 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 t5-20020a1709027fc500b001b9c34985e1si811376plb.497.2023.07.07.00.37.37; Fri, 07 Jul 2023 00:37:49 -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=POJapzSI; 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 S231976AbjGGHWs (ORCPT + 99 others); Fri, 7 Jul 2023 03:22:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229452AbjGGHWq (ORCPT ); Fri, 7 Jul 2023 03:22:46 -0400 Received: from APC01-PSA-obe.outbound.protection.outlook.com (mail-psaapc01on2134.outbound.protection.outlook.com [40.107.255.134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8BEF3211E; Fri, 7 Jul 2023 00:22:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bzkWJLnnX6IE89idvaSnKfMGcuI4QpSmEF1PqgPkTK99ljL2mI64VNN1RLKzZLHROtJzbhnROZZSux21ewoEl2qOp2KFlVKFqq0nxnfHBqzsdmgrRS01UkmAJYIB83GjVDsD1E0+4N64VhZcoRAbFjMpg4gU8FikVeKIAw5e4VvLhV13O96RELgf3xvUv0MlB7xnN3PoAiCrzGhLBpmTMdFSJ0PvnXChcyjlp6drVlhEoaJY4bbphqQz/2j2Oy2sSVEGP7IokAOHAAWvStUZN6ZagDeF3qKypnCnlG1K2rmn7g9LQ3d2z/+opCzTrzzREiu6lPhJ4MLG36+rXt0syg== 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=449EzXD50MDqlapJVYQHXZbZyaDsBh6tefDqbEGmmWg=; b=kRjnAEQtAhpIkFacpXCF2Moqa4vJEDwsjchp28dbbVUNP5snH9Jf86VGMOJVPNpBtcoFRckOwl5w/86kMxylSxI6dC8r1Ro156h0lFt9+/86HMk1Cld/gVhk9t+aIp8GzFtJDk6qdwKi+5+2G5+wWNvIFGhapSkSa/z+DIqlIoFIw6ptl6iZDAfkJfWlrH83yP2zlkG1JP0NeIhmZ94U5qm+ZtIxgGeX9iXeXOKy8m1qIdU+EhboLR7zjCfSfsiokyzLawvqHHrNVO7iYG+3lKmTcRaj/uOHqV1ooXT+fKfs1OB+on13yE4UTqHVloAmftOuzDcK6LLXDpyAu8S9Lw== 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=449EzXD50MDqlapJVYQHXZbZyaDsBh6tefDqbEGmmWg=; b=POJapzSII1NIVMXqqx4KPsOKZWkr7Nbq8aGqukRaQ41U73p5YUvVLMsDSUD8jOkhkr09dMrpeIoBcgB4fvWhnJOoyabbITYvlxzFZgnByJP0RuEWBI5hbdDLuKiwT5v+2tzLS0vHM0lvcIR/LpI+KmqdTJ1DGpxo6EwiGoOoXO3cUhpP1Nd6HuIkZQ94za0iTZvv1EvvvT9UaL/gYMZeAn+754VpPNhpb6mDZJSSDsISRDYT611F/u+XVMFbqWPKyWbEi+GHR/Sbl1PS5mLm5N2RPx6FR8ubBgkaLrzaLmXLkSlYQCSQ3VM+YnTrft/yIL8ND5loraLAktM74rRh4g== 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 SEZPR06MB5342.apcprd06.prod.outlook.com (2603:1096:101:7e::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6565.25; Fri, 7 Jul 2023 07:21:18 +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.025; Fri, 7 Jul 2023 07:21:18 +0000 From: Yangtao Li To: Thierry Reding , Mikko Perttunen , David Airlie , Daniel Vetter , Jonathan Hunter Cc: Yangtao Li , dri-devel@lists.freedesktop.org, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 12/18] drm/tegra: dpaux: Convert to devm_platform_ioremap_resource() Date: Fri, 7 Jul 2023 15:20:28 +0800 Message-Id: <20230707072034.48977-12-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230707072034.48977-1-frank.li@vivo.com> References: <20230707072034.48977-1-frank.li@vivo.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SG2PR01CA0129.apcprd01.prod.exchangelabs.com (2603:1096:4:40::33) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|SEZPR06MB5342:EE_ X-MS-Office365-Filtering-Correlation-Id: a36ee63b-f772-4493-4c5a-08db7ebac18e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: sqQqkG4FSCgluNNJB9/b6vBvdGYv06sEb3jywUWSksApu7o4w9PpujC7AP1k6wcr3KWa5IeJqscxipEtDL6IFwVnJ866Qa/Q84c3OkoEA1yasxCturIr4I9bn6+93AjNFg3nss1XEhh4a97wowqKlWcJ3KM6htlt9qQW3HvPu7zFV0yL0uB0Uaeile9XFp4OPOSTqaSNUox/3SNiORDDHoOtjFDxK70qa+EUbTKUN9W4FvE3fu0IuLXzYhKpHz8sTQtxF0etoE4GkKsfN8qOTtjFateZJW2WK9rIWTW4Db+5jJ+GlaMWsb5LN/haV1IwTUyyOkO3E4ajCz0F6zsWLASEBN+b8ZKQm0FmpfRZTLDpdaoFqdGYPaYHHmCgSoGF7QpCuzR3gr/UElzOZLhhO2r5KHYjdj5wLN2W2Y6Wnb+ek+WIQzpJvAdCcy1toHsUHi5oJAqhDy1QkKV+ykAhuZpM+RNhtqk32zeWi5Y3cDY+7dQDg+dhbREcLTILI4R2O9XSs5QPtxN91YiimQr8w5tMxQc0AmjU+Z4ufkFz+sdxSfgo71GG9uWTCvmf+agB5Rw7yDBmgEgQrG4dVbTb/Hf1VBeVM+Uu7ucitcAcdIx18Z63tH+XDch5wtKT3ezV X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(376002)(39860400002)(366004)(136003)(396003)(346002)(451199021)(41300700001)(5660300002)(110136005)(6486002)(316002)(2906002)(8676002)(8936002)(66476007)(66556008)(66946007)(36756003)(6512007)(478600001)(38350700002)(186003)(86362001)(2616005)(38100700002)(4326008)(83380400001)(6506007)(1076003)(26005)(52116002)(6666004);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?ChQCMjE7rJYrf4S/bi6DMYZAoIPIiiZNlApAlK/CQzyiv0eO/+VKdXuxBtAi?= =?us-ascii?Q?BNtXntlQWwvWnHoEEWagomJRFNJJJGsf7WGGgLbV9LS08osuImgcfX+rSwtk?= =?us-ascii?Q?cMwHQoaWn64uMnX/dOyzOzHvwpQ8h6+f/ugypKAQq6cTahDNa6yJxJp7litm?= =?us-ascii?Q?Ks1LwUySMejDNkutN3YEcQcOtMPPW/VzOdjLNpuodebcVZEoegjY0Xx3+Wp5?= =?us-ascii?Q?iL8KP0DDUEj3iwkQrvEn+3NHcYW8Kb/CSk7fbCWQ8+X0OuzMXH5dmMtxCQzv?= =?us-ascii?Q?0xibduHTvVT2FYIvr11KXDS2Rje9l76oqNFZH5exnZp+pWt9cTVNGglI9C29?= =?us-ascii?Q?leyNxPfEd3O+PwEM/BId57Sz6DxheNGMHggyRD7Nyxt9Hl7EpmtJrSAsXHGF?= =?us-ascii?Q?tSX/Tc+3YyO3mEbpJ47ju/0zIjuDMoajAQC4IbbcaBqXTj7J24ORHzBaT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nhIM5LCi0MywnDi2j814KoQ/cdSB46v?= =?us-ascii?Q?AaWi+YZCBZ4asKFFNopOfmjzT2/CvuL0WZ6gmcJ//5i76lhIXKkNxaglMB1B?= =?us-ascii?Q?X0OGhopc2g3FyjvZZqkDAIZLXDtuJ9eE4cCIxhfBsGCU+tOqcUzR5vborFd7?= =?us-ascii?Q?pEbUyONyYlic2vX/AuqScSLEzPwAPA7cgyv2O6MnbP2QzHjwRtO1YkpvZTMf?= =?us-ascii?Q?J1+AYCq1HhoUMfCx10Wumizv0mOIoUAZGyGQZ8yB?= X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: a36ee63b-f772-4493-4c5a-08db7ebac18e X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Jul 2023 07:21:18.1757 (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: AA0WdiQfesJnkJ1MksVfrdi6927HgcEsyu3HtNMU6jNAD86HlQT1ZSMWd0Rew4hMV/AGKQepsPtd4sJuUI5CQg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SEZPR06MB5342 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 Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li --- drivers/gpu/drm/tegra/dpaux.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/tegra/dpaux.c b/drivers/gpu/drm/tegra/dpaux.c index 4d2677dcd831..f120897ce4b3 100644 --- a/drivers/gpu/drm/tegra/dpaux.c +++ b/drivers/gpu/drm/tegra/dpaux.c @@ -447,7 +447,6 @@ static const struct pinmux_ops tegra_dpaux_pinmux_ops = { static int tegra_dpaux_probe(struct platform_device *pdev) { struct tegra_dpaux *dpaux; - struct resource *regs; u32 value; int err; @@ -461,14 +460,13 @@ static int tegra_dpaux_probe(struct platform_device *pdev) INIT_LIST_HEAD(&dpaux->list); dpaux->dev = &pdev->dev; - regs = platform_get_resource(pdev, IORESOURCE_MEM, 0); - dpaux->regs = devm_ioremap_resource(&pdev->dev, regs); + dpaux->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(dpaux->regs)) return PTR_ERR(dpaux->regs); dpaux->irq = platform_get_irq(pdev, 0); if (dpaux->irq < 0) - return -ENXIO; + return dpaux->irq; if (!pdev->dev.pm_domain) { dpaux->rst = devm_reset_control_get(&pdev->dev, "dpaux"); -- 2.39.0