Re: [PATCH] nvmem: core: add sanity check in nvmem_device_read()

2020-08-04 Thread Sakari Ailus
On Tue, Aug 04, 2020 at 06:44:27PM +0800, Bingbu Cao wrote: > > On 8/4/20 6:03 PM, Srinivas Kandagatla wrote: > > > > > > On 04/08/2020 10:58, Sakari Ailus wrote: > >> Hi Bingbu, > >> > >> Thank you for the patch. > >> > >> On Tue, Aug 04, 2020 at 05:13:56PM +0800, Bingbu Cao wrote: > >>>

Re: [PATCH] nvmem: core: add sanity check in nvmem_device_read()

2020-08-04 Thread Bingbu Cao
On 8/4/20 6:03 PM, Srinivas Kandagatla wrote: > > > On 04/08/2020 10:58, Sakari Ailus wrote: >> Hi Bingbu, >> >> Thank you for the patch. >> >> On Tue, Aug 04, 2020 at 05:13:56PM +0800, Bingbu Cao wrote: >>> nvmem_device_read() could be called directly once nvmem device >>> registered, the

Re: [PATCH] nvmem: core: add sanity check in nvmem_device_read()

2020-08-04 Thread Srinivas Kandagatla
On 04/08/2020 10:58, Sakari Ailus wrote: Hi Bingbu, Thank you for the patch. On Tue, Aug 04, 2020 at 05:13:56PM +0800, Bingbu Cao wrote: nvmem_device_read() could be called directly once nvmem device registered, the sanity check should be done before call nvmem_reg_read() as cell and sysfs

Re: [PATCH] nvmem: core: add sanity check in nvmem_device_read()

2020-08-04 Thread Sakari Ailus
Hi Bingbu, Thank you for the patch. On Tue, Aug 04, 2020 at 05:13:56PM +0800, Bingbu Cao wrote: > nvmem_device_read() could be called directly once nvmem device > registered, the sanity check should be done before call > nvmem_reg_read() as cell and sysfs read did now. > > Signed-off-by: Bingbu

[PATCH] nvmem: core: add sanity check in nvmem_device_read()

2020-08-04 Thread Bingbu Cao
nvmem_device_read() could be called directly once nvmem device registered, the sanity check should be done before call nvmem_reg_read() as cell and sysfs read did now. Signed-off-by: Bingbu Cao --- drivers/nvmem/core.c | 7 +++ 1 file changed, 7 insertions(+) diff --git