mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
To: Bartosz Golaszewski <brgl@bgdev.pl>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-kernel@vger.kernel.org,
	Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	stable@vger.kernel.org
Subject: Re: [PATCH] nvmem: core: don't check the return value of notifier chain call
Date: Fri, 15 Feb 2019 10:44:34 +0000	[thread overview]
Message-ID: <4c60a96c-7995-fd12-39b6-990ae0ffad4f@linaro.org> (raw)
In-Reply-To: <20190215104259.30732-1-brgl@bgdev.pl>



On 15/02/2019 10:42, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> 
> blocking_notifier_call_chain() returns the value returned by the last
> registered callback. A positive return value doesn't indicate an error
> and an nvmem device should correctly register irrespective of any
> notifier callback failures. Drop the retval check.
> 
> Fixes: bee1138bea15 ("nvmem: add a notifier chain")
> Cc: stable@vger.kernel.org
> Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>

Thanks for the fix!

Acked-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>

> ---
>   drivers/nvmem/core.c | 4 +---
>   1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/nvmem/core.c b/drivers/nvmem/core.c
> index f7301bb4ef3b..3ce65927e11c 100644
> --- a/drivers/nvmem/core.c
> +++ b/drivers/nvmem/core.c
> @@ -686,9 +686,7 @@ struct nvmem_device *nvmem_register(const struct nvmem_config *config)
>   	if (rval)
>   		goto err_remove_cells;
>   
> -	rval = blocking_notifier_call_chain(&nvmem_notifier, NVMEM_ADD, nvmem);
> -	if (rval)
> -		goto err_remove_cells;
> +	blocking_notifier_call_chain(&nvmem_notifier, NVMEM_ADD, nvmem);
>   
>   	return nvmem;
>   
> 

      reply	other threads:[~2019-02-15 10:44 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-15 10:42 Bartosz Golaszewski
2019-02-15 10:44 ` Srinivas Kandagatla [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=4c60a96c-7995-fd12-39b6-990ae0ffad4f@linaro.org \
    --to=srinivas.kandagatla@linaro.org \
    --cc=bgolaszewski@baylibre.com \
    --cc=brgl@bgdev.pl \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=stable@vger.kernel.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®