All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thierry Reding <thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: Stephen Warren <swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>,
	Liam Girdwood <lgirdwood-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw@public.gmane.org,
	linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Mark Brown <broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
Subject: Re: [PATCH 2/2] ASoC: tegra20-ac97: Convert to devm_ioremap_resource()
Date: Thu, 27 Jun 2013 12:22:12 +0200	[thread overview]
Message-ID: <20130627102211.GC15081@mithrandir> (raw)
In-Reply-To: <1372245608-15596-2-git-send-email-broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 1480 bytes --]

On Wed, Jun 26, 2013 at 12:20:08PM +0100, Mark Brown wrote:
> From: Mark Brown <broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
> 
> Signed-off-by: Mark Brown <broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
> ---
>  sound/soc/tegra/tegra20_ac97.c | 16 ++++------------
>  1 file changed, 4 insertions(+), 12 deletions(-)
> 
> diff --git a/sound/soc/tegra/tegra20_ac97.c b/sound/soc/tegra/tegra20_ac97.c
> index d8c142d..9043626d 100644
> --- a/sound/soc/tegra/tegra20_ac97.c
> +++ b/sound/soc/tegra/tegra20_ac97.c
> @@ -341,18 +341,10 @@ static int tegra20_ac97_platform_probe(struct platform_device *pdev)
>  		goto err_clk_put;
>  	}
>  
> -	memregion = devm_request_mem_region(&pdev->dev, mem->start,
> -					    resource_size(mem), DRV_NAME);
> -	if (!memregion) {
> -		dev_err(&pdev->dev, "Memory region already claimed\n");
> -		ret = -EBUSY;
> -		goto err_clk_put;
> -	}
> -
> -	regs = devm_ioremap(&pdev->dev, mem->start, resource_size(mem));
> -	if (!regs) {
> -		dev_err(&pdev->dev, "ioremap failed\n");
> -		ret = -ENOMEM;
> +	regs = devm_ioremap_resource(&pdev->dev, mem);
> +	if (IS_ERR(regs)) {
> +		ret = PTR_ERR(regs);
> +		dev_err(&pdev->dev, "ioremap failed: %d\n", ret);

Can you please remove this error message as well, please? A message to
the same effect is already output by devm_ioremap_resource(). Other than
that, looks good:

Reviewed-by: Thierry Reding <thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

  parent reply	other threads:[~2013-06-27 10:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-26 11:20 [PATCH 1/2] ASoC: tegra20-ac97: Convert to devm_clk_get() Mark Brown
     [not found] ` <1372245608-15596-1-git-send-email-broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2013-06-26 11:20   ` [PATCH 2/2] ASoC: tegra20-ac97: Convert to devm_ioremap_resource() Mark Brown
     [not found]     ` <1372245608-15596-2-git-send-email-broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2013-06-27 10:22       ` Thierry Reding [this message]
2013-06-27 11:11         ` Mark Brown
2013-06-26 17:28   ` [PATCH 1/2] ASoC: tegra20-ac97: Convert to devm_clk_get() Stephen Warren

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=20130627102211.GC15081@mithrandir \
    --to=thierry.reding-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw@public.gmane.org \
    --cc=broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=lgirdwood-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.