Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp3518164pxb; Tue, 7 Sep 2021 01:04:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxDv3gbnZ/+HFpqBric7XhFKaibBr0mLvW2jn/sxJsnqn0NyQAOemxHbK9EG6R3dC+77Dm1 X-Received: by 2002:a05:6402:70c:: with SMTP id w12mr16797636edx.289.1631001895290; Tue, 07 Sep 2021 01:04:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631001895; cv=none; d=google.com; s=arc-20160816; b=eXkRh3xffe1OJcYQDhrHkH8kLNk1VzXBZxwSAsbU0lvd3SYib9fIJZ1DZYiTLyFsVN SEicu9JhfhH61Bzzkn+mx4Z/WPWrI4mjP6PVb9xxPZ4b5mSczPy/iuKker9U/WVUCP+M /nsk7XknbzWb5n3PvMUcr+KyJU8jQe4+/zahnX5GRtIaRYlYFHx8OtGPtSL2mI+pMzgs yERWr3h7WcNRrr6Lo37Q3daWx52+iCwlhw3YxemqvUecPrVDUUSD7rgn57q+lqbPG730 qLrZw5L6rmXndYLowH+lxEPS3YkH9PnBjRllUnHkJqpbcr/bVX+RGtHyMpVVZmbw6+3L S5sQ== 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=LVDAIObtH7M9hhUCiBJMGIV1rAUlyRFsribgcuBTZgQ=; b=uGV3a6f5WNqedxKxD18Z7mOIdQmYugKgOqH5/AKc4IyLNRQ5sShiPUh9DLi3z9v4Qj 6HapbrmBUtmMTG773oE5bBA0uL0QnB5r9ld4mycFjGKh1nSBgMx/6O/l6RI/N8eL7r+H yLqTtv7gw1kuWhU7N4DjMtNj3sHUj2gvhxhwT8e2nuRlvccBGqz5p1E2Dy+VAIf5tNgI aAhCzuRn2zuRgZBecd7KI3t3slraq180D/emBEjsUNBOw4JVjNHz/1V91S6WKbUmS/4B ERrziH8wW7UWeujc7L+x6v3ON+KKnBQYz3u0CYAGf2MCzeILZnkM9KAI/YeENL2VXZTh 9ZYw== 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 kl24si9523228ejc.190.2021.09.07.01.04.32; Tue, 07 Sep 2021 01:04:55 -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 S241784AbhIGHoM (ORCPT + 99 others); Tue, 7 Sep 2021 03:44:12 -0400 Received: from mx21.baidu.com ([220.181.3.85]:44866 "EHLO baidu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S241589AbhIGHnX (ORCPT ); Tue, 7 Sep 2021 03:43:23 -0400 Received: from BC-Mail-Ex27.internal.baidu.com (unknown [172.31.51.21]) by Forcepoint Email with ESMTPS id 0376745EFBC73F9C5FD4; Tue, 7 Sep 2021 15:42:15 +0800 (CST) Received: from BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) by BC-Mail-Ex27.internal.baidu.com (172.31.51.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2; Tue, 7 Sep 2021 15:42:14 +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 15:42:14 +0800 From: Cai Huoqing To: CC: Jassi Brar , Thierry Reding , Jonathan Hunter , , Subject: [PATCH] mailbox: tegra-hsp: Make use of the helper function devm_platform_ioremap_resource() Date: Tue, 7 Sep 2021 15:42:07 +0800 Message-ID: <20210907074208.2604-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: BJHW-Mail-Ex09.internal.baidu.com (10.127.64.32) 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/mailbox/tegra-hsp.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/mailbox/tegra-hsp.c b/drivers/mailbox/tegra-hsp.c index acd0675da681..bfd70934a25e 100644 --- a/drivers/mailbox/tegra-hsp.c +++ b/drivers/mailbox/tegra-hsp.c @@ -640,7 +640,6 @@ static int tegra_hsp_request_shared_irq(struct tegra_hsp *hsp) static int tegra_hsp_probe(struct platform_device *pdev) { struct tegra_hsp *hsp; - struct resource *res; unsigned int i; u32 value; int err; @@ -654,8 +653,7 @@ static int tegra_hsp_probe(struct platform_device *pdev) INIT_LIST_HEAD(&hsp->doorbells); spin_lock_init(&hsp->lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - hsp->regs = devm_ioremap_resource(&pdev->dev, res); + hsp->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(hsp->regs)) return PTR_ERR(hsp->regs); -- 2.25.1