Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211534
b: refs/heads/master
c: e39428d
h: refs/heads/master
v: v3
  • Loading branch information
Marc Kleine-Budde authored and Ben Dooks committed Oct 18, 2010
1 parent 930e1a4 commit 1b1061e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c5b4afec8e669bbe265daea24037fccfc42c4fe3
refs/heads/master: e39428d53d080ad2615b772d7f99d2a70c2aaab2
12 changes: 3 additions & 9 deletions trunk/drivers/i2c/busses/i2c-imx.c
Original file line number Diff line number Diff line change
Expand Up @@ -159,15 +159,9 @@ static int i2c_imx_bus_busy(struct imx_i2c_struct *i2c_imx, int for_busy)

static int i2c_imx_trx_complete(struct imx_i2c_struct *i2c_imx)
{
int result;

result = wait_event_interruptible_timeout(i2c_imx->queue,
i2c_imx->i2csr & I2SR_IIF, HZ / 10);
wait_event_timeout(i2c_imx->queue, i2c_imx->i2csr & I2SR_IIF, HZ / 10);

if (unlikely(result < 0)) {
dev_dbg(&i2c_imx->adapter.dev, "<%s> result < 0\n", __func__);
return result;
} else if (unlikely(!(i2c_imx->i2csr & I2SR_IIF))) {
if (unlikely(!(i2c_imx->i2csr & I2SR_IIF))) {
dev_dbg(&i2c_imx->adapter.dev, "<%s> Timeout\n", __func__);
return -ETIMEDOUT;
}
Expand Down Expand Up @@ -295,7 +289,7 @@ static irqreturn_t i2c_imx_isr(int irq, void *dev_id)
i2c_imx->i2csr = temp;
temp &= ~I2SR_IIF;
writeb(temp, i2c_imx->base + IMX_I2C_I2SR);
wake_up_interruptible(&i2c_imx->queue);
wake_up(&i2c_imx->queue);
return IRQ_HANDLED;
}

Expand Down

0 comments on commit 1b1061e

Please sign in to comment.