summaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb/frontends/cx24110.c
diff options
context:
space:
mode:
authorAhmed S. Darwish <darwish.07@gmail.com>2007-02-14 22:57:42 -0200
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-02-21 13:35:18 -0200
commit0496daa7d88d117fab4dd190c7f6e7c4a5aa15cd (patch)
tree184317008142232cc6b90964394e35438582ad59 /drivers/media/dvb/frontends/cx24110.c
parentfd4bc4455360ff0b6ff50ec8fa5673b4da18cbb6 (diff)
V4L/DVB (5202): DVB: Use ARRAY_SIZE macro when appropriate
Use ARRAY_SIZE macro already defined in kernel.h Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com> Acked-by: Manu Abraham <manu@linuxtv.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/dvb/frontends/cx24110.c')
-rw-r--r--drivers/media/dvb/frontends/cx24110.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/dvb/frontends/cx24110.c b/drivers/media/dvb/frontends/cx24110.c
index ae96395217a..10fc0c8316d 100644
--- a/drivers/media/dvb/frontends/cx24110.c
+++ b/drivers/media/dvb/frontends/cx24110.c
@@ -254,7 +254,7 @@ static int cx24110_set_symbolrate (struct cx24110_state* state, u32 srate)
if (srate<500000)
srate=500000;
- for(i=0;(i<sizeof(bands)/sizeof(bands[0]))&&(srate>bands[i]);i++)
+ for(i = 0; (i < ARRAY_SIZE(bands)) && (srate>bands[i]); i++)
;
/* first, check which sample rate is appropriate: 45, 60 80 or 90 MHz,
and set the PLL accordingly (R07[1:0] Fclk, R06[7:4] PLLmult,
@@ -361,7 +361,7 @@ static int cx24110_initfe(struct dvb_frontend* fe)
dprintk("%s: init chip\n", __FUNCTION__);
- for(i=0;i<sizeof(cx24110_regdata)/sizeof(cx24110_regdata[0]);i++) {
+ for(i = 0; i < ARRAY_SIZE(cx24110_regdata); i++) {
cx24110_writereg(state, cx24110_regdata[i].reg, cx24110_regdata[i].data);
};