aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c
diff options
context:
space:
mode:
authorAhmed S. Darwish <darwish.07@gmail.com>2007-01-20 00:35:03 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-02-21 13:34:40 -0200
commiteca8ebfc11d1935a7dd4c59cb8defb5bdff44ecd (patch)
tree818ee1c4b8accd26a3b30599ba6058a73b9d5c02 /drivers/media/video/pvrusb2/pvrusb2-i2c-core.c
parentc1c2680d922cd36338cf3efaf4ce0067c3e26eb1 (diff)
V4L/DVB (5090): Pvrusb2: A patch to use ARRAY_SIZE macro when appropriate
Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com> Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/pvrusb2/pvrusb2-i2c-core.c')
-rw-r--r--drivers/media/video/pvrusb2/pvrusb2-i2c-core.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c b/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c
index 1a850792667..a28299107be 100644
--- a/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c
+++ b/drivers/media/video/pvrusb2/pvrusb2-i2c-core.c
@@ -976,8 +976,7 @@ static void do_i2c_scan(struct pvr2_hdw *hdw)
printk("%s: i2c scan beginning\n",hdw->name);
for (i = 0; i < 128; i++) {
msg[0].addr = i;
- rc = i2c_transfer(&hdw->i2c_adap,msg,
- sizeof(msg)/sizeof(msg[0]));
+ rc = i2c_transfer(&hdw->i2c_adap,msg, ARRAY_SIZE(msg));
if (rc != 1) continue;
printk("%s: i2c scan: found device @ 0x%x\n",hdw->name,i);
}