From: Akinobu Mita Date: Sat, 30 Mar 2019 14:01:32 +0000 (-0400) Subject: media: ov2659: fix unbalanced mutex_lock/unlock X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=384538bda10913e5c94ec5b5d34bd3075931bcf4;p=openwrt%2Fstaging%2Fblogic.git media: ov2659: fix unbalanced mutex_lock/unlock Avoid returning with mutex locked. Fixes: fa8cb6444c32 ("[media] ov2659: Don't depend on subdev API") Cc: "Lad, Prabhakar" Signed-off-by: Akinobu Mita Acked-by: Lad, Prabhakar Signed-off-by: Sakari Ailus Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/i2c/ov2659.c b/drivers/media/i2c/ov2659.c index a1e9a980a445..5ed2413eac8a 100644 --- a/drivers/media/i2c/ov2659.c +++ b/drivers/media/i2c/ov2659.c @@ -1132,7 +1132,7 @@ static int ov2659_set_fmt(struct v4l2_subdev *sd, mf = v4l2_subdev_get_try_format(sd, cfg, fmt->pad); *mf = fmt->format; #else - return -ENOTTY; + ret = -ENOTTY; #endif } else { s64 val;