diff options
Diffstat (limited to 'arch/arm/mach-omap2/board-omap3stalker.c')
-rw-r--r-- | arch/arm/mach-omap2/board-omap3stalker.c | 62 |
1 files changed, 10 insertions, 52 deletions
diff --git a/arch/arm/mach-omap2/board-omap3stalker.c b/arch/arm/mach-omap2/board-omap3stalker.c index 8e104980ea26..cb089a46f62f 100644 --- a/arch/arm/mach-omap2/board-omap3stalker.c +++ b/arch/arm/mach-omap2/board-omap3stalker.c | |||
@@ -35,12 +35,13 @@ | |||
35 | #include <asm/mach/flash.h> | 35 | #include <asm/mach/flash.h> |
36 | 36 | ||
37 | #include <plat/board.h> | 37 | #include <plat/board.h> |
38 | #include <plat/common.h> | 38 | #include "common.h" |
39 | #include <plat/gpmc.h> | 39 | #include <plat/gpmc.h> |
40 | #include <plat/nand.h> | 40 | #include <plat/nand.h> |
41 | #include <plat/usb.h> | 41 | #include <plat/usb.h> |
42 | #include <video/omapdss.h> | 42 | #include <video/omapdss.h> |
43 | #include <video/omap-panel-generic-dpi.h> | 43 | #include <video/omap-panel-generic-dpi.h> |
44 | #include <video/omap-panel-dvi.h> | ||
44 | 45 | ||
45 | #include <plat/mcspi.h> | 46 | #include <plat/mcspi.h> |
46 | #include <linux/input/matrix_keypad.h> | 47 | #include <linux/input/matrix_keypad.h> |
@@ -107,39 +108,6 @@ static void __init omap3_stalker_display_init(void) | |||
107 | return; | 108 | return; |
108 | } | 109 | } |
109 | 110 | ||
110 | static int omap3_stalker_enable_lcd(struct omap_dss_device *dssdev) | ||
111 | { | ||
112 | if (dvi_enabled) { | ||
113 | printk(KERN_ERR "cannot enable LCD, DVI is enabled\n"); | ||
114 | return -EINVAL; | ||
115 | } | ||
116 | gpio_set_value(DSS_ENABLE_GPIO, 1); | ||
117 | gpio_set_value(LCD_PANEL_BKLIGHT_GPIO, 1); | ||
118 | lcd_enabled = 1; | ||
119 | return 0; | ||
120 | } | ||
121 | |||
122 | static void omap3_stalker_disable_lcd(struct omap_dss_device *dssdev) | ||
123 | { | ||
124 | gpio_set_value(DSS_ENABLE_GPIO, 0); | ||
125 | gpio_set_value(LCD_PANEL_BKLIGHT_GPIO, 0); | ||
126 | lcd_enabled = 0; | ||
127 | } | ||
128 | |||
129 | static struct panel_generic_dpi_data lcd_panel = { | ||
130 | .name = "generic", | ||
131 | .platform_enable = omap3_stalker_enable_lcd, | ||
132 | .platform_disable = omap3_stalker_disable_lcd, | ||
133 | }; | ||
134 | |||
135 | static struct omap_dss_device omap3_stalker_lcd_device = { | ||
136 | .name = "lcd", | ||
137 | .driver_name = "generic_dpi_panel", | ||
138 | .data = &lcd_panel, | ||
139 | .phy.dpi.data_lines = 24, | ||
140 | .type = OMAP_DISPLAY_TYPE_DPI, | ||
141 | }; | ||
142 | |||
143 | static int omap3_stalker_enable_tv(struct omap_dss_device *dssdev) | 111 | static int omap3_stalker_enable_tv(struct omap_dss_device *dssdev) |
144 | { | 112 | { |
145 | return 0; | 113 | return 0; |
@@ -179,8 +147,7 @@ static void omap3_stalker_disable_dvi(struct omap_dss_device *dssdev) | |||
179 | dvi_enabled = 0; | 147 | dvi_enabled = 0; |
180 | } | 148 | } |
181 | 149 | ||
182 | static struct panel_generic_dpi_data dvi_panel = { | 150 | static struct panel_dvi_platform_data dvi_panel = { |
183 | .name = "generic", | ||
184 | .platform_enable = omap3_stalker_enable_dvi, | 151 | .platform_enable = omap3_stalker_enable_dvi, |
185 | .platform_disable = omap3_stalker_disable_dvi, | 152 | .platform_disable = omap3_stalker_disable_dvi, |
186 | }; | 153 | }; |
@@ -188,13 +155,12 @@ static struct panel_generic_dpi_data dvi_panel = { | |||
188 | static struct omap_dss_device omap3_stalker_dvi_device = { | 155 | static struct omap_dss_device omap3_stalker_dvi_device = { |
189 | .name = "dvi", | 156 | .name = "dvi", |
190 | .type = OMAP_DISPLAY_TYPE_DPI, | 157 | .type = OMAP_DISPLAY_TYPE_DPI, |
191 | .driver_name = "generic_dpi_panel", | 158 | .driver_name = "dvi", |
192 | .data = &dvi_panel, | 159 | .data = &dvi_panel, |
193 | .phy.dpi.data_lines = 24, | 160 | .phy.dpi.data_lines = 24, |
194 | }; | 161 | }; |
195 | 162 | ||
196 | static struct omap_dss_device *omap3_stalker_dss_devices[] = { | 163 | static struct omap_dss_device *omap3_stalker_dss_devices[] = { |
197 | &omap3_stalker_lcd_device, | ||
198 | &omap3_stalker_tv_device, | 164 | &omap3_stalker_tv_device, |
199 | &omap3_stalker_dvi_device, | 165 | &omap3_stalker_dvi_device, |
200 | }; | 166 | }; |
@@ -428,17 +394,6 @@ static int __init omap3_stalker_i2c_init(void) | |||
428 | static struct omap_board_config_kernel omap3_stalker_config[] __initdata = { | 394 | static struct omap_board_config_kernel omap3_stalker_config[] __initdata = { |
429 | }; | 395 | }; |
430 | 396 | ||
431 | static void __init omap3_stalker_init_early(void) | ||
432 | { | ||
433 | omap2_init_common_infrastructure(); | ||
434 | omap2_init_common_devices(mt46h32m32lf6_sdrc_params, NULL); | ||
435 | } | ||
436 | |||
437 | static void __init omap3_stalker_init_irq(void) | ||
438 | { | ||
439 | omap3_init_irq(); | ||
440 | } | ||
441 | |||
442 | static struct platform_device *omap3_stalker_devices[] __initdata = { | 397 | static struct platform_device *omap3_stalker_devices[] __initdata = { |
443 | &keys_gpio, | 398 | &keys_gpio, |
444 | }; | 399 | }; |
@@ -478,6 +433,7 @@ static void __init omap3_stalker_init(void) | |||
478 | omap_display_init(&omap3_stalker_dss_data); | 433 | omap_display_init(&omap3_stalker_dss_data); |
479 | 434 | ||
480 | omap_serial_init(); | 435 | omap_serial_init(); |
436 | omap_sdrc_init(mt46h32m32lf6_sdrc_params, NULL); | ||
481 | usb_musb_init(NULL); | 437 | usb_musb_init(NULL); |
482 | usbhs_init(&usbhs_bdata); | 438 | usbhs_init(&usbhs_bdata); |
483 | omap_ads7846_init(1, OMAP3_STALKER_TS_GPIO, 310, NULL); | 439 | omap_ads7846_init(1, OMAP3_STALKER_TS_GPIO, 310, NULL); |
@@ -494,10 +450,12 @@ static void __init omap3_stalker_init(void) | |||
494 | 450 | ||
495 | MACHINE_START(SBC3530, "OMAP3 STALKER") | 451 | MACHINE_START(SBC3530, "OMAP3 STALKER") |
496 | /* Maintainer: Jason Lam -lzg@ema-tech.com */ | 452 | /* Maintainer: Jason Lam -lzg@ema-tech.com */ |
497 | .boot_params = 0x80000100, | 453 | .atag_offset = 0x100, |
498 | .map_io = omap3_map_io, | 454 | .map_io = omap3_map_io, |
499 | .init_early = omap3_stalker_init_early, | 455 | .init_early = omap35xx_init_early, |
500 | .init_irq = omap3_stalker_init_irq, | 456 | .init_irq = omap3_init_irq, |
457 | .handle_irq = omap3_intc_handle_irq, | ||
501 | .init_machine = omap3_stalker_init, | 458 | .init_machine = omap3_stalker_init, |
502 | .timer = &omap3_secure_timer, | 459 | .timer = &omap3_secure_timer, |
460 | .restart = omap_prcm_restart, | ||
503 | MACHINE_END | 461 | MACHINE_END |