On 04.10.2019 06:07, Yizhuo Zhai wrote: > Hi Eugen: > > In function isc_interrupt(), variable "isc_intsr" and "isc_intmask" > (drivers/media/platform/atmel/atmel-isc-base.c) > could be uninitialized if regmap_read() fails and return -EINVAL . > However, they are used to decide the control flow later in the if > statement, which is potentially unsafe. > > We cannot simply return -EINVAL in isc_interrupt() because it is > out of the return type: irqreturn_t. > > Thanks for your time to check this case. > Hi Yizhuo, Thanks for your insights. The regmap_read will read directly from hardware block registers . If it fails, then it's a big hardware problem, which will lead to a lot of crashes anyway. If you feel we should initialize the variables to a safe value, I have personally nothing against it. Other people on the mailing list have a different opinion ? Thanks, Eugen