pxafb: add transparency field to pxafb_mode_info struct
authorPieter Grimmerink <p.grimmerink@inepro.com>
Fri, 13 Nov 2009 09:28:54 +0000 (10:28 +0100)
committerEric Miao <eric.y.miao@gmail.com>
Tue, 1 Dec 2009 01:02:30 +0000 (09:02 +0800)
This allows to select either RGB565 (transparency 0) or RGBT555
(transparency 1) from the mode info

Signed-off-by: Pieter Grimmerink <p.grimmerink@inepro.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
arch/arm/mach-pxa/include/mach/pxafb.h
drivers/video/pxafb.c

index f73061c90b5e438d424affb9daecc3b4a0dd4cb0..160ec83f51a62bab092d1910abd9f89bcf25eead 100644 (file)
@@ -76,7 +76,8 @@ struct pxafb_mode_info {
        u_char          bpp;
        u_int           cmap_greyscale:1,
                        depth:8,
-                       unused:23;
+                       transparency:1,
+                       unused:22;
 
        /* Parallel Mode Timing */
        u_char          hsync_len;
index 33a6aacfcbe3a6b036669bb4b1b4154b981a7fea..f58a3aae6ea630f931de2a2cc7118a65a0c344b3 100644 (file)
@@ -398,6 +398,7 @@ static void pxafb_setmode(struct fb_var_screeninfo *var,
        var->lower_margin       = mode->lower_margin;
        var->sync               = mode->sync;
        var->grayscale          = mode->cmap_greyscale;
+       var->transp.length      = mode->transparency;
 
        /* set the initial RGBA bitfields */
        pxafb_set_pixfmt(var, mode->depth);