Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp3569015pxb; Tue, 7 Sep 2021 02:42:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxB1C2ApYSarqJOBFfuKlQNsSEmuD3bXQFrrR4esvost5mpRiMWi2Yz8FKR481BnPcPsFRI X-Received: by 2002:a17:906:158f:: with SMTP id k15mr17975438ejd.241.1631007726088; Tue, 07 Sep 2021 02:42:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631007726; cv=none; d=google.com; s=arc-20160816; b=wO+qxcfEGIbN3EIXakdIDWPlxJ4ze1Ymez1zVqF0fZF94osTcniRMwFTIr4HOQlDb4 gkXOr6D8YTzhhlDwUwZMUKO/2r9FcqdFzYtjMTx/neNzjRsF3mB37ERxnOIOa92+Niib CFFP7IT37hyW11XAC8UbPrRZ6xIVOeeTh0J5gKQLdJVKGuf0w8I3doJPWxEda5Vt4r8h pha5wr3uaxEVkyWMPhOEof1xxnW9OB4t39zzlgcOLSvmt4q6B0gn6X1CVthqGYVKYKKO DFmsPEQMZXQrJKluueRsIaGmFHokdzTcfEsYV7oHGeEd3SYP7+KbtWx1j4tRp810gbNE n1Sw== 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=SiYk3LjwuMbqgUXnw8O5dJH0zNY1qTg9Y6z+SiIZ4NU=; b=Psr9SXpKOWNypm3Oqm4YtV5s8Mq62o4TMU5NGOgSNf/AD41I1n0AxvtlXcwSE9Dara y2MyAPqENis5d6CWg7AREdV9iH+1+YXxhGJI4VL/oIh8F6roL+Tc8wqlMXXnQaMeMska I7vAXJADRy/09fPLO3trjNG88Z1leIdzL/2jPpaokDB8HFPhNRkhelwlI0l/5nJWrhap Eti7UOqPbx5tKCab0fR3+xhf3eRQ3SIkxj5YAGJBZj/LUeQDzZuZb4hRI7fkTK8k4K0F TUVv9quiWPOUuvYH2m0B4ZQQr/QfIKm+vYT150uL2lNWP/HLxjaDaLDga11v8uBQs+qO qWbw== 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 ne10si10647511ejc.93.2021.09.07.02.41.42; Tue, 07 Sep 2021 02:42:06 -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 S244905AbhIGIyt (ORCPT + 99 others); Tue, 7 Sep 2021 04:54:49 -0400 Received: from mx21.baidu.com ([220.181.3.85]:37144 "EHLO baidu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S245023AbhIGIye (ORCPT ); Tue, 7 Sep 2021 04:54:34 -0400 Received: from BC-Mail-Ex10.internal.baidu.com (unknown [172.31.51.50]) by Forcepoint Email with ESMTPS id 2C61F9366C515B109760; Tue, 7 Sep 2021 16:53:26 +0800 (CST) Received: from BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) by BC-Mail-Ex10.internal.baidu.com (172.31.51.50) 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:53:25 +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:53:25 +0800 From: Cai Huoqing To: CC: =?UTF-8?q?Emilio=20L=C3=B3pez?= , Michael Turquette , Stephen Boyd , Maxime Ripard , Chen-Yu Tsai , Jernej Skrabec , , , , Subject: [PATCH] clk: sunxi: sun8i-apb0: Make use of the helper function devm_platform_ioremap_resource() Date: Tue, 7 Sep 2021 16:53:19 +0800 Message-ID: <20210907085319.5121-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/sunxi/clk-sun8i-apb0.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/clk/sunxi/clk-sun8i-apb0.c b/drivers/clk/sunxi/clk-sun8i-apb0.c index fc5d6e3b77d1..f605ecca879f 100644 --- a/drivers/clk/sunxi/clk-sun8i-apb0.c +++ b/drivers/clk/sunxi/clk-sun8i-apb0.c @@ -87,12 +87,10 @@ CLK_OF_DECLARE_DRIVER(sun8i_a23_apb0, "allwinner,sun8i-a23-apb0-clk", static int sun8i_a23_apb0_clk_probe(struct platform_device *pdev) { struct device_node *np = pdev->dev.of_node; - struct resource *r; void __iomem *reg; struct clk *clk; - r = platform_get_resource(pdev, IORESOURCE_MEM, 0); - reg = devm_ioremap_resource(&pdev->dev, r); + reg = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(reg)) return PTR_ERR(reg); -- 2.25.1