aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap1/board-osk.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap1/board-osk.c')
-rw-r--r--arch/arm/mach-omap1/board-osk.c55
1 files changed, 55 insertions, 0 deletions
diff --git a/arch/arm/mach-omap1/board-osk.c b/arch/arm/mach-omap1/board-osk.c
index e7130293a03f..1825781f4354 100644
--- a/arch/arm/mach-omap1/board-osk.c
+++ b/arch/arm/mach-omap1/board-osk.c
@@ -29,6 +29,7 @@
29#include <linux/kernel.h> 29#include <linux/kernel.h>
30#include <linux/init.h> 30#include <linux/init.h>
31#include <linux/platform_device.h> 31#include <linux/platform_device.h>
32#include <linux/interrupt.h>
32#include <linux/irq.h> 33#include <linux/irq.h>
33#include <linux/interrupt.h> 34#include <linux/interrupt.h>
34 35
@@ -292,6 +293,18 @@ static struct platform_device osk5912_kp_device = {
292 .resource = osk5912_kp_resources, 293 .resource = osk5912_kp_resources,
293}; 294};
294 295
296static struct omap_backlight_config mistral_bl_data = {
297 .default_intensity = 0xa0,
298};
299
300static struct platform_device mistral_bl_device = {
301 .name = "omap-bl",
302 .id = -1,
303 .dev = {
304 .platform_data = &mistral_bl_data,
305 },
306};
307
295static struct platform_device osk5912_lcd_device = { 308static struct platform_device osk5912_lcd_device = {
296 .name = "lcd_osk", 309 .name = "lcd_osk",
297 .id = -1, 310 .id = -1,
@@ -299,6 +312,7 @@ static struct platform_device osk5912_lcd_device = {
299 312
300static struct platform_device *mistral_devices[] __initdata = { 313static struct platform_device *mistral_devices[] __initdata = {
301 &osk5912_kp_device, 314 &osk5912_kp_device,
315 &mistral_bl_device,
302 &osk5912_lcd_device, 316 &osk5912_lcd_device,
303}; 317};
304 318
@@ -342,6 +356,38 @@ static void __init osk_mistral_init(void)
342 * can't talk to the ads or even the i2c eeprom. 356 * can't talk to the ads or even the i2c eeprom.
343 */ 357 */
344 358
359 /* parallel camera interface */
360 omap_cfg_reg(J15_1610_CAM_LCLK);
361 omap_cfg_reg(J18_1610_CAM_D7);
362 omap_cfg_reg(J19_1610_CAM_D6);
363 omap_cfg_reg(J14_1610_CAM_D5);
364 omap_cfg_reg(K18_1610_CAM_D4);
365 omap_cfg_reg(K19_1610_CAM_D3);
366 omap_cfg_reg(K15_1610_CAM_D2);
367 omap_cfg_reg(K14_1610_CAM_D1);
368 omap_cfg_reg(L19_1610_CAM_D0);
369 omap_cfg_reg(L18_1610_CAM_VS);
370 omap_cfg_reg(L15_1610_CAM_HS);
371 omap_cfg_reg(M19_1610_CAM_RSTZ);
372 omap_cfg_reg(Y15_1610_CAM_OUTCLK);
373
374 /* serial camera interface */
375 omap_cfg_reg(H19_1610_CAM_EXCLK);
376 omap_cfg_reg(W13_1610_CCP_CLKM);
377 omap_cfg_reg(Y12_1610_CCP_CLKP);
378 /* CCP_DATAM CONFLICTS WITH UART1.TX (and serial console) */
379 // omap_cfg_reg(Y14_1610_CCP_DATAM);
380 omap_cfg_reg(W14_1610_CCP_DATAP);
381
382 /* CAM_PWDN */
383 if (omap_request_gpio(11) == 0) {
384 omap_cfg_reg(N20_1610_GPIO11);
385 omap_set_gpio_direction(11, 0 /* out */);
386 omap_set_gpio_dataout(11, 0 /* off */);
387 } else
388 pr_debug("OSK+Mistral: CAM_PWDN is awol\n");
389
390
345 // omap_cfg_reg(P19_1610_GPIO6); // BUSY 391 // omap_cfg_reg(P19_1610_GPIO6); // BUSY
346 omap_cfg_reg(P20_1610_GPIO4); // PENIRQ 392 omap_cfg_reg(P20_1610_GPIO4); // PENIRQ
347 set_irq_type(OMAP_GPIO_IRQ(4), IRQT_FALLING); 393 set_irq_type(OMAP_GPIO_IRQ(4), IRQT_FALLING);
@@ -372,6 +418,15 @@ static void __init osk_mistral_init(void)
372 } else 418 } else
373 printk(KERN_ERR "OSK+Mistral: wakeup button is awol\n"); 419 printk(KERN_ERR "OSK+Mistral: wakeup button is awol\n");
374 420
421 /* LCD: backlight, and power; power controls other devices on the
422 * board, like the touchscreen, EEPROM, and wakeup (!) switch.
423 */
424 omap_cfg_reg(PWL);
425 if (omap_request_gpio(2) == 0) {
426 omap_set_gpio_direction(2, 0 /* out */);
427 omap_set_gpio_dataout(2, 1 /* on */);
428 }
429
375 platform_add_devices(mistral_devices, ARRAY_SIZE(mistral_devices)); 430 platform_add_devices(mistral_devices, ARRAY_SIZE(mistral_devices));
376} 431}
377#else 432#else