From: Antonino Daplas Date: Tue, 5 Jun 2007 20:14:33 +0000 (-0700) Subject: [VIDEO] ffb: The pseudo_palette is only 16 elements long X-Git-Tag: v2.6.22-rc5~101^2~2 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d2fa9e05e3876198d8ab31624fe84512a0a44b45;p=linux-2.6 [VIDEO] ffb: The pseudo_palette is only 16 elements long The pseudo_palette is only 16 elements long. Signed-off-by: Antonino Daplas Signed-off-by: David S. Miller --- diff --git a/drivers/video/ffb.c b/drivers/video/ffb.c index 1d4e8354b5..3f6c98fad4 100644 --- a/drivers/video/ffb.c +++ b/drivers/video/ffb.c @@ -656,7 +656,7 @@ static int ffb_setcolreg(unsigned regno, { u32 value; - if (regno >= 256) + if (regno >= 16) return 1; red >>= 8; @@ -903,7 +903,7 @@ ffb_init_fix(struct fb_info *info) struct all_info { struct fb_info info; struct ffb_par par; - u32 pseudo_palette[256]; + u32 pseudo_palette[16]; }; static int ffb_init_one(struct of_device *op)