summaryrefslogtreecommitdiffstats
path: root/drivers/media/pci/ngene/ngene-i2c.c
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2017-08-30 22:15:31 +0100
committerMark Brown <broonie@kernel.org>2017-08-30 22:15:31 +0100
commitb388dc1f62a9bdd9c4758a0664e61d0f9a9da519 (patch)
tree696fd3c245700ee59ebcf3a65b90f8773b904624 /drivers/media/pci/ngene/ngene-i2c.c
parent6969b2bae6dbe7f277a7c018b66d2f3ad662129f (diff)
parentcc4a41fe5541a73019a864883297bd5043aa6d98 (diff)
downloadlinux-b388dc1f62a9bdd9c4758a0664e61d0f9a9da519.tar.gz
linux-b388dc1f62a9bdd9c4758a0664e61d0f9a9da519.tar.bz2
linux-b388dc1f62a9bdd9c4758a0664e61d0f9a9da519.zip
Merge tag 'v4.13-rc7' into asoc-component
Linux 4.13-rc7
Diffstat (limited to 'drivers/media/pci/ngene/ngene-i2c.c')
-rw-r--r--drivers/media/pci/ngene/ngene-i2c.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/pci/ngene/ngene-i2c.c b/drivers/media/pci/ngene/ngene-i2c.c
index cf39fcf54adf..fbf36353c701 100644
--- a/drivers/media/pci/ngene/ngene-i2c.c
+++ b/drivers/media/pci/ngene/ngene-i2c.c
@@ -118,7 +118,7 @@ static int ngene_i2c_master_xfer(struct i2c_adapter *adapter,
(struct ngene_channel *)i2c_get_adapdata(adapter);
struct ngene *dev = chan->dev;
- down(&dev->i2c_switch_mutex);
+ mutex_lock(&dev->i2c_switch_mutex);
ngene_i2c_set_bus(dev, chan->number);
if (num == 2 && msg[1].flags & I2C_M_RD && !(msg[0].flags & I2C_M_RD))
@@ -136,11 +136,11 @@ static int ngene_i2c_master_xfer(struct i2c_adapter *adapter,
msg[0].buf, msg[0].len, 0))
goto done;
- up(&dev->i2c_switch_mutex);
+ mutex_unlock(&dev->i2c_switch_mutex);
return -EIO;
done:
- up(&dev->i2c_switch_mutex);
+ mutex_unlock(&dev->i2c_switch_mutex);
return num;
}