Commit 55b5c156 authored by Nishanth Aravamudan's avatar Nishanth Aravamudan Committed by David S. Miller

[SPARC64]: Make bbc_i2c use msleep_interruptible().

Signed-off-by: default avatarNishanth Aravamudan <nacc@us.ibm.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f98eeee2
...@@ -189,13 +189,13 @@ static int wait_for_pin(struct bbc_i2c_bus *bp, u8 *status) ...@@ -189,13 +189,13 @@ static int wait_for_pin(struct bbc_i2c_bus *bp, u8 *status)
while (limit-- > 0) { while (limit-- > 0) {
u8 val; u8 val;
current->state = TASK_INTERRUPTIBLE; set_current_state(TASK_INTERRUPTIBLE);
*status = val = readb(bp->i2c_control_regs + 0); *status = val = readb(bp->i2c_control_regs + 0);
if ((val & I2C_PCF_PIN) == 0) { if ((val & I2C_PCF_PIN) == 0) {
ret = 0; ret = 0;
break; break;
} }
schedule_timeout(HZ/4); msleep_interruptible(250);
} }
remove_wait_queue(&bp->wq, &wait); remove_wait_queue(&bp->wq, &wait);
bp->waiting = 0; bp->waiting = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment