From patchwork Fri Feb 17 08:49:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yang Li X-Patchwork-Id: 58429 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp775436wrn; Fri, 17 Feb 2023 00:53:37 -0800 (PST) X-Google-Smtp-Source: AK7set8gvJhDP9b2PDusI9NAlJZ/0YtlqAuP9zymzlnKKGsFq809bEf+y+MR6dZssZDJRAVOVXcY X-Received: by 2002:a17:906:5e19:b0:888:5d34:dc79 with SMTP id n25-20020a1709065e1900b008885d34dc79mr9413443eju.40.1676624017074; Fri, 17 Feb 2023 00:53:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676624017; cv=none; d=google.com; s=arc-20160816; b=XKxgRsiQyQxRGkZR0JYWXhnrgjl/ywT76szi/w8XlIPwQP7ShpDssrq5ovcQ9r6BqY ym6bUeVGL5AjIaJD5A0GdTBdxOB+WI3yWngFwVkRtZKGah519eoz3ig6iBeczyePw5Fc MZ3Ax17ylNyCMD9wtduayVnn/NyIP5+L/Fb9XsamWCA22Amh+wVfzZqjepYHgHSvowGW ujvWUXuCqF8iJlcgsBu718KD0XUny+avcnuTq9hmxm5Iuhf+WJwAWK5rBXfQRWzDEana IhTtZ/1oNmWPZQ2Q49k/Ife7DKYFzDZpy8BXRhRTlPTcexH19x0bA4U7Uok91qNqVP+y pRrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=4BjKmtCaKwVxExRXXmEeg+s9cm4APeZWLa1gmpa+NW4=; b=xvz3B0Kuu7N+QKxGpQGrkwqXP0fA6Ak0i1U254whI45LZ/jqLVm5jL8gzhwOpKOCmw WQm5GVoCQs0ecRTbKOyRTL3U1Lboq0ZWCK3pyP2/MKBMGpvdieyo2gZLwQ+SBM9HRx1V l+aDuxC3wL3wXdFZ7RjAEPAd9WD+hQZNB7/Dsc6wjeHgPkeFZevmXr4V+BLzk2f7dJE8 uAxjVpjIFhEcVoNEalnpufDvCiVKA7FTE1qvVpW57mx+VAOEaJ1h5v46nQcUKBBop42i PiRDCZrTOGl7QNSHJtURNuFfy0RMm6er9HlskgrZARKKqxuXLwMzpaDJuIH6qC3iNqJN 1/kw== ARC-Authentication-Results: i=1; mx.google.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=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 19-20020a170906001300b008b145128093si5779502eja.76.2023.02.17.00.53.14; Fri, 17 Feb 2023 00:53:37 -0800 (PST) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229672AbjBQItp (ORCPT + 99 others); Fri, 17 Feb 2023 03:49:45 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51492 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229551AbjBQItl (ORCPT ); Fri, 17 Feb 2023 03:49:41 -0500 Received: from out30-133.freemail.mail.aliyun.com (out30-133.freemail.mail.aliyun.com [115.124.30.133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1DB215FBFE for ; Fri, 17 Feb 2023 00:49:12 -0800 (PST) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R161e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018045168;MF=yang.lee@linux.alibaba.com;NM=1;PH=DS;RN=11;SR=0;TI=SMTPD_---0Vbs74z2_1676623749; Received: from localhost(mailfrom:yang.lee@linux.alibaba.com fp:SMTPD_---0Vbs74z2_1676623749) by smtp.aliyun-inc.com; Fri, 17 Feb 2023 16:49:10 +0800 From: Yang Li To: andrzej.hajda@intel.com Cc: neil.armstrong@linaro.org, rfoss@kernel.org, Laurent.pinchart@ideasonboard.com, jonas@kwiboo.se, jernej.skrabec@gmail.com, airlied@gmail.com, daniel@ffwll.ch, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Yang Li Subject: [PATCH -next] drm/bridge: analogix_dp: Use devm_platform_ioremap_resource() Date: Fri, 17 Feb 2023 16:49:08 +0800 Message-Id: <20230217084908.53524-1-yang.lee@linux.alibaba.com> X-Mailer: git-send-email 2.20.1.7.g153144c MIME-Version: 1.0 X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,USER_IN_DEF_SPF_WL 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?1758067705431122750?= X-GMAIL-MSGID: =?utf-8?q?1758067705431122750?= Convert platform_get_resource(), devm_ioremap_resource() to a single call to Use devm_platform_ioremap_resource(), as this is exactly what this function does. Signed-off-by: Yang Li --- drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c b/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c index df9370e0ff23..c6b228f1ed4c 100644 --- a/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c +++ b/drivers/gpu/drm/bridge/analogix/analogix_dp_core.c @@ -1686,7 +1686,6 @@ analogix_dp_probe(struct device *dev, struct analogix_dp_plat_data *plat_data) { struct platform_device *pdev = to_platform_device(dev); struct analogix_dp_device *dp; - struct resource *res; unsigned int irq_flags; int ret; @@ -1740,9 +1739,7 @@ analogix_dp_probe(struct device *dev, struct analogix_dp_plat_data *plat_data) clk_prepare_enable(dp->clock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - - dp->reg_base = devm_ioremap_resource(&pdev->dev, res); + dp->reg_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(dp->reg_base)) { ret = PTR_ERR(dp->reg_base); goto err_disable_clk;