Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp3574130pxb; Tue, 7 Sep 2021 02:52:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxIBKAlRuzjsGmy9nf0THaxExqclOrUSVvwLAEUbW+S0IB2t1Ei+5t6SiFnvRt3Aqzn83w7 X-Received: by 2002:a17:906:4482:: with SMTP id y2mr17550472ejo.484.1631008328156; Tue, 07 Sep 2021 02:52:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631008328; cv=none; d=google.com; s=arc-20160816; b=fWz1QCjWt6uertTBI6Pgel3Wm6x9Hkn3bqZLJ5UABceQ3ZAWgo7k4xgxntaXu16MQi gwK+/Mf0JTdJzPAv6byUZf4uDuQEICKOYwq2eS0PQmtZ3f8fQVH+Ys9YwcDSIVb1iJ6t 2bdpIcEHfwj2RD0u9EMsv5U6KoiZarDr/+pCLpSEMuCTpMC2I2iaFMK+uY5ry0PJw0s7 y6knlU02AENRLRfwKId3wFk1NVBNnVCqtA4rjphVzFBAGi0wIPk93t2/DxOTQglAWIE8 yY4i3x7HvFN6j3euY/uWQnt2P20nSGSb5ajxw44+NOk84F43nFqr07Ab2xJ5hgq8OOmR CGCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=E7McAoFt5F8Fs4xdBD5aWKvwxPPAgdNvwU9EaamNopw=; b=Jid9jq85CDT1yUzKyQIKP3PhVXqb412/sfLFyhyMh3hp3CvYE6o5delZQoLANzVZkT V+KVG0nJjGTioxRdSyT+p6NblqgX1yo7uzCWNSZwY4wHC1bQNYoSCTBaQLIN1XLd1ORN TStxb6SELoAEF2MAqb4IwAYisHbbpDIfIgmz9WKPVZfwzB72ncoLnTktp7sV1fFbJXtq mkuUqckCfDluV8Z9gF/jwNKmMLuKSXQiCOb4fcnXp6Brtcc2iuVFuBas/cVA0F4DjdM2 dQgXSZvm2WPmfUXXQQqWCB+UgBJeezas7oX760SXKuei7nPR78rRbUWiKqcnY4q6pat2 lP1g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bx16si9911320ejb.146.2021.09.07.02.51.22; Tue, 07 Sep 2021 02:52:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243347AbhIGItI (ORCPT + 99 others); Tue, 7 Sep 2021 04:49:08 -0400 Received: from mx20.baidu.com ([111.202.115.85]:59430 "EHLO baidu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S242828AbhIGItH (ORCPT ); Tue, 7 Sep 2021 04:49:07 -0400 Received: from BC-Mail-Ex07.internal.baidu.com (unknown [172.31.51.47]) by Forcepoint Email with ESMTPS id 17CC8ECA11F6C6423C4D; Tue, 7 Sep 2021 16:47:59 +0800 (CST) Received: from BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) by BC-Mail-EX07.internal.baidu.com (172.31.51.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2242.12; Tue, 7 Sep 2021 16:47:58 +0800 Received: from LAPTOP-UKSR4ENP.internal.baidu.com (172.31.63.8) by BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2308.14; Tue, 7 Sep 2021 16:47:58 +0800 From: Cai Huoqing To: CC: Michael Turquette , Stephen Boyd , , Subject: [PATCH] clk: gemini: Make use of the helper function devm_platform_ioremap_resource() Date: Tue, 7 Sep 2021 16:47:52 +0800 Message-ID: <20210907084752.3642-1-caihuoqing@baidu.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [172.31.63.8] X-ClientProxiedBy: BC-Mail-Ex09.internal.baidu.com (172.31.51.49) To BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use the devm_platform_ioremap_resource() helper instead of calling platform_get_resource() and devm_ioremap_resource() separately Signed-off-by: Cai Huoqing --- drivers/clk/clk-gemini.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/clk/clk-gemini.c b/drivers/clk/clk-gemini.c index b51069e794ff..0184ff9bd206 100644 --- a/drivers/clk/clk-gemini.c +++ b/drivers/clk/clk-gemini.c @@ -276,7 +276,6 @@ static int gemini_clk_probe(struct platform_device *pdev) struct device *dev = &pdev->dev; struct device_node *np = dev->of_node; unsigned int mult, div; - struct resource *res; u32 val; int ret; int i; @@ -286,8 +285,7 @@ static int gemini_clk_probe(struct platform_device *pdev) return -ENOMEM; /* Remap the system controller for the exclusive register */ - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - base = devm_ioremap_resource(dev, res); + base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(base)) return PTR_ERR(base); -- 2.25.1