Skip to content
Snippets Groups Projects
Commit fedbb362 authored by Ville Syrjala's avatar Ville Syrjala Committed by Linus Torvalds
Browse files

sm501fb: RGB offsets are reversed in 16bpp modes


The RGB offsets were reversed in 16bpp modes.  Simply trying to reverse the
offsets when endianness differs is clearly the wrong thing to do but that is
an issue for another patch.

Signed-off-by: default avatarVille Syrjala <syrjala@sci.fi>
Acked-by: default avatarBen Dooks <ben-linux@fluff.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 5619d823
No related branches found
No related tags found
No related merge requests found
......@@ -286,13 +286,13 @@ static int sm501fb_check_var(struct fb_var_screeninfo *var,
case 16:
if (sm->pdata->flags & SM501_FBPD_SWAP_FB_ENDIAN) {
var->red.offset = 11;
var->green.offset = 5;
var->blue.offset = 0;
} else {
var->blue.offset = 11;
var->green.offset = 5;
var->red.offset = 0;
} else {
var->red.offset = 11;
var->green.offset = 5;
var->blue.offset = 0;
}
var->red.length = 5;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment