All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alan Ott <alan@signal11.us>
To: Christophe JAILLET <christophe.jaillet@wanadoo.fr>,
	alex.aring@gmail.com, stefan@osg.samsung.com
Cc: linux-wpan@vger.kernel.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH v2] mrf24j40: Fix en error handling path in 'mrf24j40_probe()'
Date: Mon, 10 Jul 2017 15:24:17 -0400	[thread overview]
Message-ID: <581ccccf-a605-3472-a4a6-9ccb99c78da1@signal11.us> (raw)
In-Reply-To: <20170708084013.18620-1-christophe.jaillet@wanadoo.fr>

On 07/08/2017 04:40 AM, Christophe JAILLET wrote:
> If this check fails, we must release some resources as done everywhere
> else in this function before returning an error code.
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
> V2: initialization of ret in this erro path ws missing. Stupid me!
> ---
>  drivers/net/ieee802154/mrf24j40.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ieee802154/mrf24j40.c b/drivers/net/ieee802154/mrf24j40.c
> index 7d334963dc08..da8683782ffc 100644
> --- a/drivers/net/ieee802154/mrf24j40.c
> +++ b/drivers/net/ieee802154/mrf24j40.c
> @@ -1330,7 +1330,8 @@ static int mrf24j40_probe(struct spi_device *spi)
>  	if (spi->max_speed_hz > MAX_SPI_SPEED_HZ) {
>  		dev_warn(&spi->dev, "spi clock above possible maximum: %d",
>  			 MAX_SPI_SPEED_HZ);
> -		return -EINVAL;
> +		ret = -EINVAL;
> +		goto err_register_device;
>  	}
>
>  	ret = mrf24j40_hw_init(devrec);
>

Acked-by: Alan Ott <alan@signal11.us>

WARNING: multiple messages have this Message-ID (diff)
From: Alan Ott <alan@signal11.us>
To: Christophe JAILLET <christophe.jaillet@wanadoo.fr>,
	alex.aring@gmail.com, stefan@osg.samsung.com
Cc: linux-wpan@vger.kernel.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH v2] mrf24j40: Fix en error handling path in 'mrf24j40_probe()'
Date: Mon, 10 Jul 2017 19:24:17 +0000	[thread overview]
Message-ID: <581ccccf-a605-3472-a4a6-9ccb99c78da1@signal11.us> (raw)
In-Reply-To: <20170708084013.18620-1-christophe.jaillet@wanadoo.fr>

On 07/08/2017 04:40 AM, Christophe JAILLET wrote:
> If this check fails, we must release some resources as done everywhere
> else in this function before returning an error code.
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
> V2: initialization of ret in this erro path ws missing. Stupid me!
> ---
>  drivers/net/ieee802154/mrf24j40.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ieee802154/mrf24j40.c b/drivers/net/ieee802154/mrf24j40.c
> index 7d334963dc08..da8683782ffc 100644
> --- a/drivers/net/ieee802154/mrf24j40.c
> +++ b/drivers/net/ieee802154/mrf24j40.c
> @@ -1330,7 +1330,8 @@ static int mrf24j40_probe(struct spi_device *spi)
>  	if (spi->max_speed_hz > MAX_SPI_SPEED_HZ) {
>  		dev_warn(&spi->dev, "spi clock above possible maximum: %d",
>  			 MAX_SPI_SPEED_HZ);
> -		return -EINVAL;
> +		ret = -EINVAL;
> +		goto err_register_device;
>  	}
>
>  	ret = mrf24j40_hw_init(devrec);
>

Acked-by: Alan Ott <alan@signal11.us>


  reply	other threads:[~2017-07-10 19:24 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-08  8:40 [PATCH v2] mrf24j40: Fix en error handling path in 'mrf24j40_probe()' Christophe JAILLET
2017-07-08  8:40 ` Christophe JAILLET
2017-07-10 19:24 ` Alan Ott [this message]
2017-07-10 19:24   ` Alan Ott
2017-07-11  6:48 ` Marcel Holtmann
2017-07-11  6:48   ` Marcel Holtmann

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=581ccccf-a605-3472-a4a6-9ccb99c78da1@signal11.us \
    --to=alan@signal11.us \
    --cc=alex.aring@gmail.com \
    --cc=christophe.jaillet@wanadoo.fr \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wpan@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stefan@osg.samsung.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 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.