Skip to content

Commit

Permalink
V4L/DVB (6563): tda8290: optimize for loop in tda829x_probe function
Browse files Browse the repository at this point in the history
Thanks to Trent Piepho for pointing this out.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
  • Loading branch information
Michael Krufky authored and Mauro Carvalho Chehab committed Jan 25, 2008
1 parent 98ae127 commit bbe1e0b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/media/video/tda8290.c
Original file line number Diff line number Diff line change
Expand Up @@ -754,9 +754,8 @@ int tda829x_probe(struct tuner *t)
tuner_i2c_xfer_send(&i2c_props, soft_reset, 1);
tuner_i2c_xfer_recv(&i2c_props, buf, PROBE_BUFFER_SIZE);
for (i = 1; i < PROBE_BUFFER_SIZE; i++) {
if (buf[i] == buf[0])
continue;
break;
if (buf[i] != buf[0])
break;
}

/* all bytes are equal, not a tda829x - probably a tda9887 */
Expand Down

0 comments on commit bbe1e0b

Please sign in to comment.