]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/media/video/ir-kbd-i2c.c
V4L/DVB (5585): SN9C1xx driver updates
[linux-2.6-omap-h63xx.git] / drivers / media / video / ir-kbd-i2c.c
index 59edf58204de311935cc3d807b7d2bd3745c148d..ed92b6f7187a6eac7b3e5da338b20995abc2a0bb 100644 (file)
@@ -31,7 +31,6 @@
 #include <linux/moduleparam.h>
 #include <linux/init.h>
 #include <linux/kernel.h>
-#include <linux/sched.h>
 #include <linux/string.h>
 #include <linux/timer.h>
 #include <linux/delay.h>
@@ -174,7 +173,7 @@ static int get_key_pinnacle(struct IR_i2c *ir, u32 *ir_key, u32 *ir_raw,
                return -EIO;
        }
 
-       for (start = 0; start<4; start++) {
+       for (start = 0; start < ARRAY_SIZE(b); start++) {
                if (b[start] == marker) {
                        code=b[(start+parity_offset+1)%4];
                        parity=b[(start+parity_offset)%4];