Commit 55a4ea71 authored by Evgeny Budilovsky's avatar Evgeny Budilovsky Committed by Greg Kroah-Hartman

staging/cptm1217: fix checkpatch warnings about else clause

Signed-off-by: default avatarEvgeny Budilovsky <budevg@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 2a838c64
...@@ -147,13 +147,12 @@ static int cp_tm1217_read(struct cp_tm1217_device *ts, ...@@ -147,13 +147,12 @@ static int cp_tm1217_read(struct cp_tm1217_device *ts,
msleep(WAIT_FOR_RESPONSE); msleep(WAIT_FOR_RESPONSE);
for (i = 0; i < MAX_RETRIES; i++) { for (i = 0; i < MAX_RETRIES; i++) {
retval = i2c_master_recv(ts->client, &req[1], size); retval = i2c_master_recv(ts->client, &req[1], size);
if (retval == size) { if (retval == size)
break; break;
} else {
msleep(INCREMENTAL_DELAY); msleep(INCREMENTAL_DELAY);
dev_dbg(ts->dev, "cp_tm1217: Retry count is %d\n", i); dev_dbg(ts->dev, "cp_tm1217: Retry count is %d\n", i);
} }
}
if (retval != size) if (retval != size)
dev_err(ts->dev, "cp_tm1217: Read from device failed\n"); dev_err(ts->dev, "cp_tm1217: Read from device failed\n");
...@@ -288,10 +287,10 @@ static irqreturn_t cp_tm1217_sample_thread(int irq, void *handle) ...@@ -288,10 +287,10 @@ static irqreturn_t cp_tm1217_sample_thread(int irq, void *handle)
if (ts->thread_running == 1) { if (ts->thread_running == 1) {
mutex_unlock(&ts->thread_mutex); mutex_unlock(&ts->thread_mutex);
return IRQ_HANDLED; return IRQ_HANDLED;
} else { }
ts->thread_running = 1; ts->thread_running = 1;
mutex_unlock(&ts->thread_mutex); mutex_unlock(&ts->thread_mutex);
}
/* Mask the interrupts */ /* Mask the interrupts */
retval = cp_tm1217_mask_interrupt(ts); retval = cp_tm1217_mask_interrupt(ts);
......
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