2 * File: drivers/video/omap/lcd_palmz71.c
4 * LCD panel support for the Palm Zire71
6 * Original version : Romain Goyet
7 * Current version : Laurent Gonzalez
8 * Modified for zire71 : Marek Vasut
10 * This program is free software; you can redistribute it and/or modify it
11 * under the terms of the GNU General Public License as published by the
12 * Free Software Foundation; either version 2 of the License, or (at your
13 * option) any later version.
15 * This program is distributed in the hope that it will be useful, but
16 * WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * General Public License for more details.
20 * You should have received a copy of the GNU General Public License along
21 * with this program; if not, write to the Free Software Foundation, Inc.,
22 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
25 #include <linux/module.h>
26 #include <linux/platform_device.h>
30 #include <asm/arch/gpio.h>
31 #include <asm/arch/omapfb.h>
33 static int palmz71_panel_init(struct lcd_panel *panel,
34 struct omapfb_device *fbdev)
39 static void palmz71_panel_cleanup(struct lcd_panel *panel)
44 static int palmz71_panel_enable(struct lcd_panel *panel)
49 static void palmz71_panel_disable(struct lcd_panel *panel)
53 static unsigned long palmz71_panel_get_caps(struct lcd_panel *panel)
55 return OMAPFB_CAPS_SET_BACKLIGHT;
58 struct lcd_panel palmz71_panel = {
60 .config = OMAP_LCDC_PANEL_TFT | OMAP_LCDC_INV_VSYNC |
61 OMAP_LCDC_INV_HSYNC | OMAP_LCDC_HSVS_RISING_EDGE |
62 OMAP_LCDC_HSVS_OPPOSITE,
76 .init = palmz71_panel_init,
77 .cleanup = palmz71_panel_cleanup,
78 .enable = palmz71_panel_enable,
79 .disable = palmz71_panel_disable,
80 .get_caps = palmz71_panel_get_caps,
83 static int palmz71_panel_probe(struct platform_device *pdev)
85 omapfb_register_panel(&palmz71_panel);
89 static int palmz71_panel_remove(struct platform_device *pdev)
94 static int palmz71_panel_suspend(struct platform_device *pdev, pm_message_t mesg)
99 static int palmz71_panel_resume(struct platform_device *pdev)
104 struct platform_driver palmz71_panel_driver = {
105 .probe = palmz71_panel_probe,
106 .remove = palmz71_panel_remove,
107 .suspend = palmz71_panel_suspend,
108 .resume = palmz71_panel_resume,
110 .name = "lcd_palmz71",
111 .owner = THIS_MODULE,
115 static int palmz71_panel_drv_init(void)
117 return platform_driver_register(&palmz71_panel_driver);
120 static void palmz71_panel_drv_cleanup(void)
122 platform_driver_unregister(&palmz71_panel_driver);
125 module_init(palmz71_panel_drv_init);
126 module_exit(palmz71_panel_drv_cleanup);