]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
media: gspca: properly check for errors in po1030_probe()
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 3 May 2021 11:57:30 +0000 (13:57 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 Jun 2021 06:22:08 +0000 (08:22 +0200)
commit7e8596496aa8f28882f058afb0b27d4fd653bbd9
tree1285f47958117be56358c6e99be75b6e043761b9
parentf7adc025facdc000053bfd89f552e3c33ed5cd22
media: gspca: properly check for errors in po1030_probe()

[ Upstream commit dacb408ca6f0e34df22b40d8dd5fae7f8e777d84 ]

If m5602_write_sensor() or m5602_write_bridge() fail, do not continue to
initialize the device but return the error to the calling funtion.

Cc: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Link: https://lore.kernel.org/r/20210503115736.2104747-64-gregkh@linuxfoundation.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/media/usb/gspca/m5602/m5602_po1030.c