Skip to content

Commit

Permalink
[PATCH] fbdev: Static pseudocolor with depth less than 4 does exist
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Antonino A. Daplas authored and Linus Torvalds committed Jun 26, 2006
1 parent ae6d321 commit 0c683db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/video/fbmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down

0 comments on commit 0c683db

Please sign in to comment.