From: Lars-Peter Clausen <lars@metafoo.de>
To: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
Cc: cbou@mail.ru, dwmw2@infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] drivres/power/jz4740-battery.c: Use devm_request_and_ioremap
Date: Fri, 09 Nov 2012 10:42:11 +0100 [thread overview]
Message-ID: <509CCFF3.60706@metafoo.de> (raw)
In-Reply-To: <1352243472-14951-3-git-send-email-marcos.souza.org@gmail.com>
On 11/07/2012 12:11 AM, Marcos Paulo de Souza wrote:
> No functional changes. Just a cleanup.
>
> Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
Looks good to me:
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
One minor comment though:
> ---
> drivers/power/jz4740-battery.c | 33 +++++++--------------------------
> 1 file changed, 7 insertions(+), 26 deletions(-)
>
> diff --git a/drivers/power/jz4740-battery.c b/drivers/power/jz4740-battery.c
> index 59900c6..e4ec7eb 100644
> --- a/drivers/power/jz4740-battery.c
> +++ b/drivers/power/jz4740-battery.c
>[...]
> - jz_battery->base = ioremap_nocache(jz_battery->mem->start,
> - resource_size(jz_battery->mem));
> + jz_battery->base = devm_request_and_ioremap(&pdev->dev, mem);
> if (!jz_battery->base) {
> - ret = -EBUSY;
> - dev_err(&pdev->dev, "Failed to ioremap mmio memory\n");
> - goto err_release_mem_region;
> + dev_err(&pdev->dev, "Failed to request/ioremap mmio memory\n");
devm_request_and_ioremap will print its own error messages if it fails, so
strictly speaking this is not necessary, but I don't think it is worth doing
resend just for this.
Anton, maybe you can just remove the line when applying the patch.
Thanks,
- Lars
> + return -EBUSY;
> }
>
[...]
next prev parent reply other threads:[~2012-11-09 9:42 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-06 23:11 [PATCH 0/2 v3] jz4740-battery module cleanup Marcos Paulo de Souza
2012-11-06 23:11 ` [PATCH 1/2] drivers/power/jz4740-battery.c: Use devm_kzalloc Marcos Paulo de Souza
2012-11-06 23:11 ` [PATCH 2/2] drivres/power/jz4740-battery.c: Use devm_request_and_ioremap Marcos Paulo de Souza
2012-11-09 9:42 ` Lars-Peter Clausen [this message]
2012-11-19 0:12 ` Anton Vorontsov
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=509CCFF3.60706@metafoo.de \
--to=lars@metafoo.de \
--cc=cbou@mail.ru \
--cc=dwmw2@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marcos.souza.org@gmail.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
all inboxes | Powered by JetHome®