]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blob - drivers/video/omap/lcd_inn1510.c
d6ae2f6533c39baf8a5c352c15dceed900297c77
[linux-2.6-omap-h63xx.git] / drivers / video / omap / lcd_inn1510.c
1 /*
2  * File: drivers/video/omap/lcd-inn1510.c
3  *
4  * LCD panel support for the TI OMAP1510 Innovator board
5  *
6  * Copyright (C) 2004 Nokia Corporation
7  * Author: Imre Deak <imre.deak@nokia.com>
8  *
9  * This program is free software; you can redistribute it and/or modify it
10  * under the terms of the GNU General Public License as published by the
11  * Free Software Foundation; either version 2 of the License, or (at your
12  * option) any later version.
13  *
14  * This program is distributed in the hope that it will be useful, but
15  * WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17  * General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License along
20  * with this program; if not, write to the Free Software Foundation, Inc.,
21  * 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22  */
23
24 #include <linux/module.h>
25
26 #include <asm/io.h>
27
28 #include <asm/arch/fpga.h>
29 #include <asm/arch/omapfb.h>
30
31 /* #define OMAPFB_DBG 1 */
32
33 #include "debug.h"
34
35 static int innovator1510_panel_init(struct omapfb_device *fbdev)
36 {
37         DBGENTER(1);
38         DBGLEAVE(1);
39         return 0;
40 }
41
42 static void innovator1510_panel_cleanup(void)
43 {
44         DBGENTER(1);
45         DBGLEAVE(1);
46 }
47
48 static int innovator1510_panel_enable(void)
49 {
50         DBGENTER(1);
51
52         fpga_write(0x7, OMAP1510_FPGA_LCD_PANEL_CONTROL);
53
54         DBGLEAVE(1);
55         return 0;
56 }
57
58 static void innovator1510_panel_disable(void)
59 {
60         DBGENTER(1);
61
62         fpga_write(0x0, OMAP1510_FPGA_LCD_PANEL_CONTROL);
63
64         DBGLEAVE(1);
65 }
66
67 static unsigned long innovator1510_panel_get_caps(void)
68 {
69         return 0;
70 }
71
72 struct lcd_panel innovator1510_panel = {
73         .name           = "inn1510",
74         .config         = OMAP_LCDC_PANEL_TFT,
75
76         .bpp            = 16,
77         .data_lines     = 16,
78         .x_res          = 240,
79         .y_res          = 320,
80         .pixel_clock    = 12500,
81         .hsw            = 40,
82         .hfp            = 40,
83         .hbp            = 72,
84         .vsw            = 1,
85         .vfp            = 1,
86         .vbp            = 0,
87         .pcd            = 12,
88
89         .init           = innovator1510_panel_init,
90         .cleanup        = innovator1510_panel_cleanup,
91         .enable         = innovator1510_panel_enable,
92         .disable        = innovator1510_panel_disable,
93         .get_caps       = innovator1510_panel_get_caps,
94 };
95