2 * LCD panel driver for Samsung LTE430WQ-F0C
4 * Author: Steve Sakoman <steve@sakoman.com>
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 as published by
8 * the Free Software Foundation.
10 * This program is distributed in the hope that it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
15 * You should have received a copy of the GNU General Public License along with
16 * this program. If not, see <http://www.gnu.org/licenses/>.
19 #include <linux/module.h>
20 #include <linux/delay.h>
22 #include <plat/display.h>
24 static struct omap_video_timings samsung_lte_timings
= {
39 static int samsung_lte_panel_probe(struct omap_dss_device
*dssdev
)
41 dssdev
->panel
.config
= OMAP_DSS_LCD_TFT
| OMAP_DSS_LCD_IVS
|
43 dssdev
->panel
.timings
= samsung_lte_timings
;
48 static void samsung_lte_panel_remove(struct omap_dss_device
*dssdev
)
52 static int samsung_lte_panel_enable(struct omap_dss_device
*dssdev
)
56 /* wait couple of vsyncs until enabling the LCD */
59 if (dssdev
->platform_enable
)
60 r
= dssdev
->platform_enable(dssdev
);
65 static void samsung_lte_panel_disable(struct omap_dss_device
*dssdev
)
67 if (dssdev
->platform_disable
)
68 dssdev
->platform_disable(dssdev
);
70 /* wait at least 5 vsyncs after disabling the LCD */
75 static int samsung_lte_panel_suspend(struct omap_dss_device
*dssdev
)
77 samsung_lte_panel_disable(dssdev
);
81 static int samsung_lte_panel_resume(struct omap_dss_device
*dssdev
)
83 return samsung_lte_panel_enable(dssdev
);
86 static struct omap_dss_driver samsung_lte_driver
= {
87 .probe
= samsung_lte_panel_probe
,
88 .remove
= samsung_lte_panel_remove
,
90 .enable
= samsung_lte_panel_enable
,
91 .disable
= samsung_lte_panel_disable
,
92 .suspend
= samsung_lte_panel_suspend
,
93 .resume
= samsung_lte_panel_resume
,
96 .name
= "samsung_lte_panel",
101 static int __init
samsung_lte_panel_drv_init(void)
103 return omap_dss_register_driver(&samsung_lte_driver
);
106 static void __exit
samsung_lte_panel_drv_exit(void)
108 omap_dss_unregister_driver(&samsung_lte_driver
);
111 module_init(samsung_lte_panel_drv_init
);
112 module_exit(samsung_lte_panel_drv_exit
);
113 MODULE_LICENSE("GPL");