aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@linuxtv.org>2007-11-05 09:54:42 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-01-25 19:02:02 -0200
commitbbe1e0ba527a18e1ddda2eabb9da369e5bcf556e (patch)
treec963b06fc0f093156fc5918f29cacea255fde0e0
parentV4L/DVB (6562): Make HVR900 to use also tveeprom (diff)
downloadlinux-dev-bbe1e0ba527a18e1ddda2eabb9da369e5bcf556e.tar.xz
linux-dev-bbe1e0ba527a18e1ddda2eabb9da369e5bcf556e.zip
V4L/DVB (6563): tda8290: optimize for loop in tda829x_probe function
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>
-rw-r--r--drivers/media/video/tda8290.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/media/video/tda8290.c b/drivers/media/video/tda8290.c
index a849ded0000d..c606f3c38cf4 100644
--- a/drivers/media/video/tda8290.c
+++ b/drivers/media/video/tda8290.c
@@ -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 */