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, 13 May 2021 16:58:32 +0000 (18:58 +0200)
commitdacb408ca6f0e34df22b40d8dd5fae7f8e777d84
tree7fa353f5126c0b24e288407f223fb1d007a4e591
parent8e23e83c752b54e98102627a1cc09281ad71a299
media: gspca: properly check for errors in po1030_probe()

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>
drivers/media/usb/gspca/m5602/m5602_po1030.c