aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-integrator/integrator_cp.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-30 15:42:33 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-30 15:42:33 -0700
commit1d651f3332340c232ff66b7f5bab66cb8903859f (patch)
tree99c47c498867ff5ee2fe0845622f4d1c4e1df1f4 /arch/arm/mach-integrator/integrator_cp.c
parentMerge of master.kernel.org:/home/rmk/linux-2.6-rmk.git (diff)
parent[PATCH] ARM: IntegratorCP: Fix CLCD MUX selection values (diff)
downloadlinux-dev-1d651f3332340c232ff66b7f5bab66cb8903859f.tar.xz
linux-dev-1d651f3332340c232ff66b7f5bab66cb8903859f.zip
Merge of master.kernel.org:/home/rmk/linux-2.6-rmk.git
Diffstat (limited to 'arch/arm/mach-integrator/integrator_cp.c')
-rw-r--r--arch/arm/mach-integrator/integrator_cp.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/arch/arm/mach-integrator/integrator_cp.c b/arch/arm/mach-integrator/integrator_cp.c
index 68e15c36e336..3b948e8c2751 100644
--- a/arch/arm/mach-integrator/integrator_cp.c
+++ b/arch/arm/mach-integrator/integrator_cp.c
@@ -420,7 +420,22 @@ static struct clcd_panel vga = {
*/
static void cp_clcd_enable(struct clcd_fb *fb)
{
- cm_control(CM_CTRL_LCDMUXSEL_MASK, CM_CTRL_LCDMUXSEL_VGA);
+ u32 val;
+
+ if (fb->fb.var.bits_per_pixel <= 8)
+ val = CM_CTRL_LCDMUXSEL_VGA_8421BPP;
+ else if (fb->fb.var.bits_per_pixel <= 16)
+ val = CM_CTRL_LCDMUXSEL_VGA_16BPP;
+ else
+ val = 0; /* no idea for this, don't trust the docs */
+
+ cm_control(CM_CTRL_LCDMUXSEL_MASK|
+ CM_CTRL_LCDEN0|
+ CM_CTRL_LCDEN1|
+ CM_CTRL_STATIC1|
+ CM_CTRL_STATIC2|
+ CM_CTRL_STATIC|
+ CM_CTRL_n24BITEN, val);
}
static unsigned long framesize = SZ_1M;