Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp3517279pxb; Tue, 7 Sep 2021 01:03:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxHgizM/pjOgW3ZlX1Q4AWCqDdNt3L2GYd6Dt6G0kA1g0riGuY8bMZgKlBmPpDCcIB61Ehx X-Received: by 2002:a05:6402:27d4:: with SMTP id c20mr17042228ede.332.1631001809165; Tue, 07 Sep 2021 01:03:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631001809; cv=none; d=google.com; s=arc-20160816; b=kZgekDEOzKoWihQmMvm1x8Fj2XcAXEAOD70w3c0YJwxIWNWhGpZE9CNdAmikjBUqb0 EfeR5LVOUDsEcDBmejnSEud9WFz7A0jBrIU8dJKW5lpQnAIZ0k1GIfuG7W9VDlc+o3SA KvONyaLClzntk8NOsrRvYIWoRPNneBKq8W6KyoRo0gAbQac8vA+bgyoAa4pmso3D9ds2 XcyVtN/p6GjEV//JtmUg9IUyAh+VMnG5WfStIcmCEBP7B7Z2tnTH9tSxaz/nl56utGNo gq2oxHJPdBGpFAmSHgJuIKg0lSEwnYdd7gsmsNXIjlbf/9bYL9YRRSvLArAOS72mzeLK lKDw== 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=G7BWq/G9utxl6wnVMSpZtXjBiUU+1330yvr7tn6BWXM=; b=Jdw6pEDbd46XojG1CYvlkhddKKX6TxtXgJlUYOVOKL3AMmdemhn3u4EI3+A1NC0i8j V8qEfVlZq5fchL4TvPG7jCvXRvjVD9MlGU87WZgr8W5qONU8zkJ0Owejzay0bCnyU2RL p4yeqPkg7xcHZEt09urdjYdj65iBoAI5cnkf0q6KHAaNzhJzsf0h1VcLB1FZibP267jT MxgTTLn8JP0ZOx11+i4G+/9+hN1i5iNomETQ6wH0dj9xkPTigYWm3gEYCfIid69vTNDP qRtu14+y0YAUhuPAiJaZtnTewebgVWo2mqgpchJHCQRRNqHmkaEH5i1mKRU+N5kUUVzV cssw== 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 d10si9728222ejo.371.2021.09.07.01.03.05; Tue, 07 Sep 2021 01:03:29 -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 S240480AbhIGHnf (ORCPT + 99 others); Tue, 7 Sep 2021 03:43:35 -0400 Received: from mx20.baidu.com ([111.202.115.85]:44332 "EHLO baidu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S240240AbhIGHnA (ORCPT ); Tue, 7 Sep 2021 03:43:00 -0400 Received: from BC-Mail-Ex31.internal.baidu.com (unknown [172.31.51.25]) by Forcepoint Email with ESMTPS id E5D66C304FA57E82B249; Tue, 7 Sep 2021 15:41:52 +0800 (CST) Received: from BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) by BC-Mail-Ex31.internal.baidu.com (172.31.51.25) 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 15:41:52 +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:41:52 +0800 From: Cai Huoqing To: CC: Jassi Brar , Subject: [PATCH] mailbox: sti: Make use of the helper function devm_platform_ioremap_resource() Date: Tue, 7 Sep 2021 15:41:46 +0800 Message-ID: <20210907074146.2451-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/mailbox-sti.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/mailbox/mailbox-sti.c b/drivers/mailbox/mailbox-sti.c index ab3a6ab762d3..823061dd8c8e 100644 --- a/drivers/mailbox/mailbox-sti.c +++ b/drivers/mailbox/mailbox-sti.c @@ -408,7 +408,6 @@ static int sti_mbox_probe(struct platform_device *pdev) struct sti_mbox_device *mdev; struct device_node *np = pdev->dev.of_node; struct mbox_chan *chans; - struct resource *res; int irq; int ret; @@ -425,8 +424,7 @@ static int sti_mbox_probe(struct platform_device *pdev) platform_set_drvdata(pdev, mdev); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - mdev->base = devm_ioremap_resource(&pdev->dev, res); + mdev->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(mdev->base)) return PTR_ERR(mdev->base); -- 2.25.1