All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: Wei Yongjun <weiyj.lk@gmail.com>
Cc: rmody@brocade.com, huangj@brocade.com, davem@davemloft.net,
	yongjun_wei@trendmicro.com.cn, netdev@vger.kernel.org
Subject: Re: [PATCH] bna: add missing iounmap() on error in bnad_init()
Date: Mon, 13 May 2013 18:01:45 +0400	[thread overview]
Message-ID: <5190F249.9020309@cogentembedded.com> (raw)
In-Reply-To: <CAPgLHd8G816BcF7U6eG320w=k9Zv-yVYjt4wreyU67eSdVRERg@mail.gmail.com>

Hello.

On 13-05-2013 11:26, Wei Yongjun wrote:

> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>

> Add the missing iounmap() before return from bnad_init()
> in the error handling case.
> Introduced by commit 01b54b1451853593739816a392485c4e2bee7dda
> (bna: tx rx cleanup fix).

> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> ---
>   drivers/net/ethernet/brocade/bna/bnad.c | 4 +++-
>   1 file changed, 3 insertions(+), 1 deletion(-)

> diff --git a/drivers/net/ethernet/brocade/bna/bnad.c b/drivers/net/ethernet/brocade/bna/bnad.c
> index ce4a030..59da9eb 100644
> --- a/drivers/net/ethernet/brocade/bna/bnad.c
> +++ b/drivers/net/ethernet/brocade/bna/bnad.c
> @@ -3237,8 +3237,10 @@ bnad_init(struct bnad *bnad,
>   	sprintf(bnad->wq_name, "%s_wq_%d", BNAD_NAME, bnad->id);
>   	bnad->work_q = create_singlethread_workqueue(bnad->wq_name);
>

    Empty line not needed here -- maybe it's time to delete it?

> -	if (!bnad->work_q)
> +	if (!bnad->work_q) {
> +		iounmap(bnad->bar0);
>   		return -ENOMEM;
> +	}
>
>   	return 0;
>   }

WBR, Sergei

      reply	other threads:[~2013-05-13 14:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-13  7:26 [PATCH] bna: add missing iounmap() on error in bnad_init() Wei Yongjun
2013-05-13 14:01 ` Sergei Shtylyov [this message]

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=5190F249.9020309@cogentembedded.com \
    --to=sergei.shtylyov@cogentembedded.com \
    --cc=davem@davemloft.net \
    --cc=huangj@brocade.com \
    --cc=netdev@vger.kernel.org \
    --cc=rmody@brocade.com \
    --cc=weiyj.lk@gmail.com \
    --cc=yongjun_wei@trendmicro.com.cn \
    /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.