diff options
Diffstat (limited to 'drivers/i2c/busses/i2c-i801.c')
-rw-r--r-- | drivers/i2c/busses/i2c-i801.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/i2c/busses/i2c-i801.c b/drivers/i2c/busses/i2c-i801.c index 10411848fd70..9d2c5adf5d4f 100644 --- a/drivers/i2c/busses/i2c-i801.c +++ b/drivers/i2c/busses/i2c-i801.c | |||
@@ -237,7 +237,7 @@ static int i801_transaction(int xact) | |||
237 | status = inb_p(SMBHSTSTS); | 237 | status = inb_p(SMBHSTSTS); |
238 | } while ((status & SMBHSTSTS_HOST_BUSY) && (timeout++ < MAX_TIMEOUT)); | 238 | } while ((status & SMBHSTSTS_HOST_BUSY) && (timeout++ < MAX_TIMEOUT)); |
239 | 239 | ||
240 | result = i801_check_post(status, timeout >= MAX_TIMEOUT); | 240 | result = i801_check_post(status, timeout > MAX_TIMEOUT); |
241 | if (result < 0) | 241 | if (result < 0) |
242 | return result; | 242 | return result; |
243 | 243 | ||
@@ -257,9 +257,9 @@ static void i801_wait_hwpec(void) | |||
257 | } while ((!(status & SMBHSTSTS_INTR)) | 257 | } while ((!(status & SMBHSTSTS_INTR)) |
258 | && (timeout++ < MAX_TIMEOUT)); | 258 | && (timeout++ < MAX_TIMEOUT)); |
259 | 259 | ||
260 | if (timeout >= MAX_TIMEOUT) { | 260 | if (timeout > MAX_TIMEOUT) |
261 | dev_dbg(&I801_dev->dev, "PEC Timeout!\n"); | 261 | dev_dbg(&I801_dev->dev, "PEC Timeout!\n"); |
262 | } | 262 | |
263 | outb_p(status, SMBHSTSTS); | 263 | outb_p(status, SMBHSTSTS); |
264 | } | 264 | } |
265 | 265 | ||
@@ -344,7 +344,7 @@ static int i801_block_transaction_byte_by_byte(union i2c_smbus_data *data, | |||
344 | while ((!(status & SMBHSTSTS_BYTE_DONE)) | 344 | while ((!(status & SMBHSTSTS_BYTE_DONE)) |
345 | && (timeout++ < MAX_TIMEOUT)); | 345 | && (timeout++ < MAX_TIMEOUT)); |
346 | 346 | ||
347 | result = i801_check_post(status, timeout >= MAX_TIMEOUT); | 347 | result = i801_check_post(status, timeout > MAX_TIMEOUT); |
348 | if (result < 0) | 348 | if (result < 0) |
349 | return result; | 349 | return result; |
350 | 350 | ||