]> Pileus Git - ~andy/linux/blobdiff - drivers/video/pmagb-b-fb.c
x86, atomic64: In selftest, distinguish x86-64 from 586+
[~andy/linux] / drivers / video / pmagb-b-fb.c
index 98748723af9f88cf5e433de72889f69e6b0f7ef0..2de0806421b49b450c5a9c73b12aceec4719f3cd 100644 (file)
@@ -102,7 +102,8 @@ static int pmagbbfb_setcolreg(unsigned int regno, unsigned int red,
 {
        struct pmagbbfb_par *par = info->par;
 
-       BUG_ON(regno >= info->cmap.len);
+       if (regno >= info->cmap.len)
+               return 1;
 
        red   >>= 8;    /* The cmap fields are 16 bits    */
        green >>= 8;    /* wide, but the hardware colormap */