Re: Potential NULL pointer deference in spi

2019-10-11 Thread Eric Dumazet
On 10/10/19 10:31 PM, Yizhuo Zhai wrote: > Hi Eric: > > My apologies for bothering, we got those report via static analysis > and haven't got a good method to verify the path to trigger them. > Therefore I sent those email to you maintainers first since you > know much better about the

Re: Potential NULL pointer deference in spi

2019-10-10 Thread Yizhuo Zhai
Hi Eric: My apologies for bothering, we got those report via static analysis and haven't got a good method to verify the path to trigger them. Therefore I sent those email to you maintainers first since you know much better about the details. Sorry again for your time and I take your suggestions.

Re: Potential NULL pointer deference in spi

2019-10-09 Thread Eric Dumazet
On 10/9/19 10:37 PM, Yizhuo Zhai wrote: > Hi All: > > drivers/spi/spi.c: > > The function to_spi_device() could return NULL, but some callers > in this file does not check the return value while directly dereference > it, which seems potentially unsafe. > > Such callers include

Potential NULL pointer deference in spi

2019-10-09 Thread Yizhuo Zhai
Hi All: drivers/spi/spi.c: The function to_spi_device() could return NULL, but some callers in this file does not check the return value while directly dereference it, which seems potentially unsafe. Such callers include spidev_release(), spi_dev_check(), driver_override_store(), etc. --