提交 e613f8fa 编写于 作者: A Antti Palosaari 提交者: Mauro Carvalho Chehab

V4L/DVB (9140): anysee: unlock I2C-mutex in error case

- unlock I2C-mutex also in error case
Signed-off-by: NAntti Palosaari <crope@iki.fi>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 45d01103
...@@ -178,14 +178,14 @@ static int anysee_master_xfer(struct i2c_adapter *adap, struct i2c_msg *msg, ...@@ -178,14 +178,14 @@ static int anysee_master_xfer(struct i2c_adapter *adap, struct i2c_msg *msg,
inc = 1; inc = 1;
} }
if (ret) if (ret)
return ret; break;
i += inc; i += inc;
} }
mutex_unlock(&d->i2c_mutex); mutex_unlock(&d->i2c_mutex);
return i; return ret ? ret : i;
} }
static u32 anysee_i2c_func(struct i2c_adapter *adapter) static u32 anysee_i2c_func(struct i2c_adapter *adapter)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册