[PATCH] drivers/video/radeonfb.c: fix an array overflow
This patch fixes an array overflow found by the Coverity checker.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
diff --git a/drivers/video/radeonfb.c b/drivers/video/radeonfb.c
index d9a084e..c463870 100644
--- a/drivers/video/radeonfb.c
+++ b/drivers/video/radeonfb.c
@@ -2107,7 +2107,7 @@
if (rinfo->arch == RADEON_M6) {
- for (i=0; i<8; i++)
+ for (i=0; i<7; i++)
OUTREG(common_regs_m6[i].reg, common_regs_m6[i].val);
} else {
for (i=0; i<9; i++)