From patchwork Wed Mar 8 05:49:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yang Li X-Patchwork-Id: 66026 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp167095wrd; Tue, 7 Mar 2023 22:25:26 -0800 (PST) X-Google-Smtp-Source: AK7set/y/X7wQ+KR5H3WrjUtDpG33JDV9kLJEQvXIHk1H7kRaOFOlSi41JExe9A5Iw7VSsz1Heqt X-Received: by 2002:a05:6402:32c:b0:4c1:2252:f729 with SMTP id q12-20020a056402032c00b004c12252f729mr15910536edw.30.1678256726557; Tue, 07 Mar 2023 22:25:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1678256726; cv=none; d=google.com; s=arc-20160816; b=qBF34wlGlOpUX3gJofqOqQoBIC61HXcgti7WV+QDIQWdUdbeysqbXflW7qQr0jfbVQ 1H2LWXppUJDvoSt5Y4/FCchWjxhjpzXj8srLE54Sbv4x1B18oSgWqCTc05DruF0YkKRW rpWelNgs8t+gduMNkc5etbekI30Jr6L4THn1K7jNWevFYB/LEmYM/lhz2EC8BnMo/SN5 tvc9eBHj2wFRWt6V866+QBX2VErzRqFuAwdUa21mtp2gUjeq+oG7l/zqtJ5R32ravjhi u8USe6fWU7PMDYXiWtvi5yo6Jk7SsB+CnBjMaeLaYbIn2zXxLxCAH6+S5BtpirERn/bz nXAQ== 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=jyUjx7E0YhQk/OnPTLVigyqa+ufIC5I2iHK6qP31CDo=; b=n0WOXspqQjzKF13qyleS4YWdOcZIjSJK41jNHzE7NzITKkk2klFQ1euIsq2KyVLFZa TxsO2Sg88j8mUpXjSWs/cR7ZWTYboMgpxFkhX5Rvzv+GDxN9PY9Cq4Si34uEjawefu9N gR4fBpxtRtd8DGU4eSJ+gZ3xGMgwHRrShj/CahJtZDUyiTHcg7HivIziWSutP4tCso2p MKTyJUKM/agP9ZV5rlIINpyXJNUJ/FxrPg6GlvUyCe66QpkTlLSSi/61CvlEcCpkxGvS aCUo5J3exmv/4Uc4PA7kWwU/OUR3VNfNP0iOkuylXSV330SnvXxQutwkac2MvGVUHvpy OSEA== 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 r10-20020a056402034a00b004c46c30198asi3477260edw.45.2023.03.07.22.25.02; Tue, 07 Mar 2023 22:25:26 -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 S229736AbjCHFt7 (ORCPT + 99 others); Wed, 8 Mar 2023 00:49:59 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35620 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229508AbjCHFt5 (ORCPT ); Wed, 8 Mar 2023 00:49:57 -0500 Received: from out30-100.freemail.mail.aliyun.com (out30-100.freemail.mail.aliyun.com [115.124.30.100]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 84327A21A2; Tue, 7 Mar 2023 21:49:55 -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=ay29a033018046060;MF=yang.lee@linux.alibaba.com;NM=1;PH=DS;RN=6;SR=0;TI=SMTPD_---0VdO7NrG_1678254592; Received: from localhost(mailfrom:yang.lee@linux.alibaba.com fp:SMTPD_---0VdO7NrG_1678254592) by smtp.aliyun-inc.com; Wed, 08 Mar 2023 13:49:53 +0800 From: Yang Li To: deller@gmx.de Cc: linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Yang Li Subject: [PATCH -next] fbdev/clps711x-fb: Use devm_platform_get_and_ioremap_resource() Date: Wed, 8 Mar 2023 13:49:50 +0800 Message-Id: <20230308054950.15164-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,RCVD_IN_MSPIKE_H2, 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?1759779725549880912?= X-GMAIL-MSGID: =?utf-8?q?1759779725549880912?= According to commit 890cc39a8799 ("drivers: provide devm_platform_get_and_ioremap_resource()"), convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: Yang Li --- drivers/video/fbdev/clps711x-fb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/video/fbdev/clps711x-fb.c b/drivers/video/fbdev/clps711x-fb.c index 45c75ff01eca..c8bfc608bd9c 100644 --- a/drivers/video/fbdev/clps711x-fb.c +++ b/drivers/video/fbdev/clps711x-fb.c @@ -238,8 +238,7 @@ static int clps711x_fb_probe(struct platform_device *pdev) info->fix.mmio_start = res->start; info->fix.mmio_len = resource_size(res); - res = platform_get_resource(pdev, IORESOURCE_MEM, 1); - info->screen_base = devm_ioremap_resource(dev, res); + info->screen_base = devm_platform_get_and_ioremap_resource(pdev, 1, &res); if (IS_ERR(info->screen_base)) { ret = PTR_ERR(info->screen_base); goto out_fb_release;