Skip to content
Commit 0c980e3f authored by Yizhuo's avatar Yizhuo Committed by Mauro Carvalho Chehab
Browse files

media: atomisp: fix the uninitialized use and rename "retvalue"

Inside function mt9m114_detect(), variable "retvalue" could
be uninitialized if mt9m114_read_reg() returns error, however, it
is used in the later if statement, which is potentially unsafe.

The local variable "retvalue" is renamed to "model" to avoid
confusion.

Link: https://lore.kernel.org/linux-media/20210625053858.3862-1-yzhai003@ucr.edu


Fixes: ad85094b ("Revert "media: staging: atomisp: Remove driver"")
Signed-off-by: default avatarYizhuo <yzhai003@ucr.edu>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent 9d971b81
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment