linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Mika Westerberg <mika.westerberg@linux.intel.com>,
	linux-gpio@vger.kernel.org,
	Linus Walleij <linus.walleij@linaro.org>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: [PATCH v1 2/4] pinctrl: cherryview: Use devm_platform_ioremap_resource()
Date: Wed,  3 Jul 2019 17:56:13 +0300	[thread overview]
Message-ID: <20190703145615.74768-2-andriy.shevchenko@linux.intel.com> (raw)
In-Reply-To: <20190703145615.74768-1-andriy.shevchenko@linux.intel.com>

Use the new helper that wraps the calls to platform_get_resource()
and devm_ioremap_resource() together.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/pinctrl/intel/pinctrl-cherryview.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/pinctrl/intel/pinctrl-cherryview.c b/drivers/pinctrl/intel/pinctrl-cherryview.c
index d0740714b3cb..6e7da421b6c9 100644
--- a/drivers/pinctrl/intel/pinctrl-cherryview.c
+++ b/drivers/pinctrl/intel/pinctrl-cherryview.c
@@ -1689,7 +1689,6 @@ static int chv_pinctrl_probe(struct platform_device *pdev)
 {
 	struct chv_pinctrl *pctrl;
 	struct acpi_device *adev;
-	struct resource *res;
 	acpi_status status;
 	int ret, irq, i;
 
@@ -1717,8 +1716,7 @@ static int chv_pinctrl_probe(struct platform_device *pdev)
 	if (!pctrl->saved_pin_context)
 		return -ENOMEM;
 
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	pctrl->regs = devm_ioremap_resource(&pdev->dev, res);
+	pctrl->regs = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(pctrl->regs))
 		return PTR_ERR(pctrl->regs);
 
-- 
2.20.1


  reply	other threads:[~2019-07-03 14:56 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-03 14:56 [PATCH v1 1/4] pinctrl: baytrail: Use devm_platform_ioremap_resource() Andy Shevchenko
2019-07-03 14:56 ` Andy Shevchenko [this message]
2019-07-03 14:56 ` [PATCH v1 3/4] pinctrl: intel: " Andy Shevchenko
2019-07-03 14:56 ` [PATCH v1 4/4] pinctrl: merrifield: " Andy Shevchenko
2019-07-03 16:36 ` [PATCH v1 1/4] pinctrl: baytrail: " Mika Westerberg
2019-07-23 15:51   ` Andy Shevchenko
2019-07-28 22:06     ` Linus Walleij
2019-07-29  9:37       ` Andy Shevchenko
2019-07-29 21:25         ` Linus Walleij

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190703145615.74768-2-andriy.shevchenko@linux.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).