]> err.no Git - linux-2.6/commitdiff
[PATCH] fbdev: Static pseudocolor with depth less than 4 does exist
authorAntonino A. Daplas <adaplas@gmail.com>
Mon, 26 Jun 2006 07:26:36 +0000 (00:26 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 26 Jun 2006 16:58:29 +0000 (09:58 -0700)
A static pseudocolor visual with depth less than 4 does exist, so let's not
accidentally upscale the depth with this configuration

Signed-off-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
drivers/video/fbmem.c

index 9bb6763d0cb8694c8af7c68ab80bac5e1cdd922f..2529805ed1c78c4285223513da0c3db157524289 100644 (file)
@@ -433,7 +433,7 @@ int fb_prepare_logo(struct fb_info *info, int rotate)
                        depth = info->var.green.length;
        }
 
-       if (info->fix.visual == FB_VISUAL_STATIC_PSEUDOCOLOR) {
+       if (info->fix.visual == FB_VISUAL_STATIC_PSEUDOCOLOR && depth > 4) {
                /* assume console colormap */
                depth = 4;
        }