aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPavel Pisa <pisa@cmp.felk.cvut.cz>2007-10-16 04:29:44 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-16 12:43:21 -0400
commit9da505d1f9d8facbb688d28dfb6d9fc8edfd5c4a (patch)
treed8c4ef21015f64c3d61cd6be14859d8a67705963
parentce4c371a9de1f5b9e1d15f9d59c5f7d079bcd6d7 (diff)
imxfb: fast read flag and nonstandard field configurable
The i.MX frame-buffer read operation should be faster for all configurations then drawing each individual character again in response to scroll events. The nonstandard fields allows to configure frame-buffer special options flags for different display configurations by board specific initialization code. One of such specific options is reversed order of pixels in each individual byte. i.MX frame-buffer seems to be designed for big-endian use first. The byte order is correctly configured for little-endian ordering, but if 1, 2 or 4 bits per pixel are used, pixels ordering is incompatible to Linux generic frame-buffer drawing functions. The patch "Allow generic BitBLT functions to work with swapped pixel order in bytes" introduces required functionality into FBDEV core. The pixels ordering selection has to be enabled at compile time CONFIG_FB_CFB_REV_PIXELS_IN_BYTE and for each display configuration which requires it by flag FB_NONSTD_REV_PIX_IN_B in "nonstd" field of info structure. This patch provides way for board specific code to select this option. Signed-off-by: Pavel Pisa <pisa@cmp.felk.cvut.cz> Signed-off-by: Antonino Daplas <adaplas@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--drivers/video/imxfb.c3
-rw-r--r--include/asm-arm/arch-imx/imxfb.h1
2 files changed, 3 insertions, 1 deletions
diff --git a/drivers/video/imxfb.c b/drivers/video/imxfb.c
index 986ffa6c70a3..11609552a387 100644
--- a/drivers/video/imxfb.c
+++ b/drivers/video/imxfb.c
@@ -466,7 +466,7 @@ static int __init imxfb_init_fbinfo(struct device *dev)
466 info->var.vmode = FB_VMODE_NONINTERLACED; 466 info->var.vmode = FB_VMODE_NONINTERLACED;
467 467
468 info->fbops = &imxfb_ops; 468 info->fbops = &imxfb_ops;
469 info->flags = FBINFO_FLAG_DEFAULT; 469 info->flags = FBINFO_FLAG_DEFAULT | FBINFO_READS_FAST;
470 470
471 fbi->rgb[RGB_16] = &def_rgb_16; 471 fbi->rgb[RGB_16] = &def_rgb_16;
472 fbi->rgb[RGB_8] = &def_rgb_8; 472 fbi->rgb[RGB_8] = &def_rgb_8;
@@ -479,6 +479,7 @@ static int __init imxfb_init_fbinfo(struct device *dev)
479 info->var.yres_virtual = inf->yres; 479 info->var.yres_virtual = inf->yres;
480 fbi->max_bpp = inf->bpp; 480 fbi->max_bpp = inf->bpp;
481 info->var.bits_per_pixel = inf->bpp; 481 info->var.bits_per_pixel = inf->bpp;
482 info->var.nonstd = inf->nonstd;
482 info->var.pixclock = inf->pixclock; 483 info->var.pixclock = inf->pixclock;
483 info->var.hsync_len = inf->hsync_len; 484 info->var.hsync_len = inf->hsync_len;
484 info->var.left_margin = inf->left_margin; 485 info->var.left_margin = inf->left_margin;
diff --git a/include/asm-arm/arch-imx/imxfb.h b/include/asm-arm/arch-imx/imxfb.h
index 7dbc7bbba65d..3ed9ec8b9f00 100644
--- a/include/asm-arm/arch-imx/imxfb.h
+++ b/include/asm-arm/arch-imx/imxfb.h
@@ -7,6 +7,7 @@ struct imxfb_mach_info {
7 u_short xres; 7 u_short xres;
8 u_short yres; 8 u_short yres;
9 9
10 u_int nonstd;
10 u_char bpp; 11 u_char bpp;
11 u_char hsync_len; 12 u_char hsync_len;
12 u_char left_margin; 13 u_char left_margin;