lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2ef927a7-0698-3d2f-797f-b9f742bce905@linaro.org>
Date:   Fri, 15 Feb 2019 10:26:02 +0000
From:   Srinivas Kandagatla <srinivas.kandagatla@...aro.org>
To:     Bartosz Golaszewski <brgl@...ev.pl>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Bartosz Golaszewski <bgolaszewski@...libre.com>,
        stable <stable@...r.kernel.org>
Subject: Re: [PATCH] nvmem: core: fix the return value check when calling the
 notifier chain



On 15/02/2019 09:41, Bartosz Golaszewski wrote:
>> rval will be masked with STOP MASK, so the above statement could be
>> false even if we have error.
>> So you should consider returning an errono which can be understood by user:
>>
>> may be something like this:
>>
>> if (rval & NOTIFY_STOP_MASK) {
>>          rval = notifier_to_errno(rval);
>>          goto err_remove_cells
>> }
>>
> Actually I'm now thinking we can remove this check at all - most users
> never check the return values of notifier chain calls. This function
> cannot fail in itself. What do you think?
Thats even better, I was about to suggest the same on the fact that we 
should allow nvmem provider to register to be successful irrespective of 
the notifier callback failures.

--srini

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ