From: Silviu-Mihai Popescu <silviupopescu1990@gmail.com>
To: linux-mtd@lists.infradead.org
Cc: David Woodhouse <dwmw2@infradead.org>,
Artem Bityutskiy <artem.bityutskiy@linux.intel.com>,
Philip Avinash <avinashphilip@ti.com>,
Peter Korsgaard <jacmet@sunsite.dk>,
linux-kernel@vger.kernel.org,
Silviu-Mihai Popescu <silviupopescu1990@gmail.com>
Subject: [PATCH] drivers: mtd: devices: convert to devm_ioremap_resource()
Date: Thu, 11 Apr 2013 00:01:51 +0300 [thread overview]
Message-ID: <1365627711-17476-1-git-send-email-silviupopescu1990@gmail.com> (raw)
Convert all uses of devm_request_and_ioremap() to the newly introduced
devm_ioremap_resource() which provides more consistent error handling.
Signed-off-by: Silviu-Mihai Popescu <silviupopescu1990@gmail.com>
---
drivers/mtd/devices/elm.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mtd/devices/elm.c b/drivers/mtd/devices/elm.c
index 2ec5da9..2bafb06 100644
--- a/drivers/mtd/devices/elm.c
+++ b/drivers/mtd/devices/elm.c
@@ -344,9 +344,9 @@ static int elm_probe(struct platform_device *pdev)
return -ENODEV;
}
- info->elm_base = devm_request_and_ioremap(&pdev->dev, res);
- if (!info->elm_base)
- return -EADDRNOTAVAIL;
+ info->elm_base = devm_ioremap_resource(&pdev->dev, res);
+ if (IS_ERR(info->elm_base))
+ return PTR_ERR(info->elm_base);
ret = devm_request_irq(&pdev->dev, irq->start, elm_isr, 0,
pdev->name, info);
--
1.7.9.5
next reply other threads:[~2013-04-10 21:02 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-10 21:01 Silviu-Mihai Popescu [this message]
2013-05-10 14:43 ` Artem Bityutskiy
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=1365627711-17476-1-git-send-email-silviupopescu1990@gmail.com \
--to=silviupopescu1990@gmail.com \
--cc=artem.bityutskiy@linux.intel.com \
--cc=avinashphilip@ti.com \
--cc=dwmw2@infradead.org \
--cc=jacmet@sunsite.dk \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
/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
all inboxes | Powered by JetHome®