*/
#include <linux/module.h>
+#include <linux/platform_device.h>
#include <asm/io.h>
-#include <asm/arch/fpga.h>
-#include "omapfb.h"
+#include <asm/arch/fpga.h>
+#include <asm/arch/omapfb.h>
/* #define OMAPFB_DBG 1 */
#include "debug.h"
-static int palmte_panel_init(struct lcd_panel *panel)
+static int palmte_panel_init(struct omapfb_device *panel)
{
DBGENTER(1);
DBGLEAVE(1);
return 0;
}
-static void palmte_panel_cleanup(struct lcd_panel *panel)
+static void palmte_panel_cleanup(void)
{
DBGENTER(1);
DBGLEAVE(1);
}
-static int palmte_panel_enable(struct lcd_panel *panel)
+static int palmte_panel_enable(void)
{
DBGENTER(1);
DBGLEAVE(1);
return 0;
}
-static void palmte_panel_disable(struct lcd_panel *panel)
+static void palmte_panel_disable(void)
{
DBGENTER(1);
DBGLEAVE(1);
}
-static unsigned long palmte_panel_get_caps(struct lcd_panel *panel)
+static unsigned long palmte_panel_get_caps(void)
{
return 0;
}
.name = "palmte",
.config = OMAP_LCDC_PANEL_TFT | OMAP_LCDC_INV_VSYNC |
OMAP_LCDC_INV_HSYNC | OMAP_LCDC_HSVS_RISING_EDGE |
- OMAP_LCDC_HSVS_OPPOSITE;
+ OMAP_LCDC_HSVS_OPPOSITE,
.data_lines = 16,
.bpp = 8,
- .pixel_clock = 12500,
+ .pixel_clock = 12000,
.x_res = 320,
.y_res = 320,
.hsw = 4,
.vsw = 1,
.vfp = 8,
.vbp = 7,
- .pcd = 5,
+ .pcd = 0,
.init = palmte_panel_init,
.cleanup = palmte_panel_cleanup,
.get_caps = palmte_panel_get_caps,
};
+static int palmte_panel_probe(struct platform_device *pdev)
+{
+ DBGENTER(1);
+ omapfb_register_panel(&palmte_panel);
+ return 0;
+}
+
+static int palmte_panel_remove(struct platform_device *pdev)
+{
+ DBGENTER(1);
+ return 0;
+}
+
+static int palmte_panel_suspend(struct platform_device *pdev, pm_message_t mesg)
+{
+ DBGENTER(1);
+ return 0;
+}
+
+static int palmte_panel_resume(struct platform_device *pdev)
+{
+ DBGENTER(1);
+ return 0;
+}
+
+struct platform_driver palmte_panel_driver = {
+ .probe = palmte_panel_probe,
+ .remove = palmte_panel_remove,
+ .suspend = palmte_panel_suspend,
+ .resume = palmte_panel_resume,
+ .driver = {
+ .name = "lcd_palmte",
+ .owner = THIS_MODULE,
+ },
+};
+
+static int palmte_panel_drv_init(void)
+{
+ return platform_driver_register(&palmte_panel_driver);
+}
+
+static void palmte_panel_drv_cleanup(void)
+{
+ platform_driver_unregister(&palmte_panel_driver);
+}
+
+module_init(palmte_panel_drv_init);
+module_exit(palmte_panel_drv_cleanup);