Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 1 | /* |
| 2 | * linux/arch/arm/mach-omap1/board-palmte.c |
| 3 | * |
| 4 | * Modified from board-generic.c |
| 5 | * |
| 6 | * Support for the Palm Tungsten E PDA. |
| 7 | * |
| 8 | * Original version : Laurent Gonzalez |
| 9 | * |
| 10 | * Maintainters : http://palmtelinux.sf.net |
| 11 | * palmtelinux-developpers@lists.sf.net |
| 12 | * |
| 13 | * This program is free software; you can redistribute it and/or modify |
| 14 | * it under the terms of the GNU General Public License version 2 as |
| 15 | * published by the Free Software Foundation. |
| 16 | */ |
| 17 | |
| 18 | #include <linux/kernel.h> |
| 19 | #include <linux/init.h> |
| 20 | #include <linux/platform_device.h> |
| 21 | #include <linux/notifier.h> |
Russell King | f8ce254 | 2006-01-07 16:15:52 +0000 | [diff] [blame] | 22 | #include <linux/clk.h> |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 23 | |
| 24 | #include <asm/hardware.h> |
| 25 | #include <asm/mach-types.h> |
| 26 | #include <asm/mach/arch.h> |
| 27 | #include <asm/mach/map.h> |
| 28 | |
| 29 | #include <asm/arch/gpio.h> |
| 30 | #include <asm/arch/mux.h> |
| 31 | #include <asm/arch/usb.h> |
| 32 | #include <asm/arch/board.h> |
| 33 | #include <asm/arch/common.h> |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 34 | |
| 35 | static void __init omap_generic_init_irq(void) |
| 36 | { |
Tony Lindgren | 87bd63f | 2006-02-08 22:06:46 +0000 | [diff] [blame] | 37 | omap1_init_common_hw(); |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 38 | omap_init_irq(); |
| 39 | } |
| 40 | |
Tony Lindgren | 9b6553c | 2006-04-02 17:46:30 +0100 | [diff] [blame] | 41 | static struct platform_device palmte_lcd_device = { |
| 42 | .name = "lcd_palmte", |
| 43 | .id = -1, |
| 44 | }; |
| 45 | |
| 46 | static struct platform_device *devices[] __initdata = { |
| 47 | &palmte_lcd_device, |
| 48 | }; |
| 49 | |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 50 | static struct omap_usb_config palmte_usb_config __initdata = { |
| 51 | .register_dev = 1, |
| 52 | .hmc_mode = 0, |
| 53 | .pins[0] = 3, |
| 54 | }; |
| 55 | |
| 56 | static struct omap_mmc_config palmte_mmc_config __initdata = { |
| 57 | .mmc [0] = { |
| 58 | .enabled = 1, |
| 59 | .wire4 = 1, |
| 60 | .wp_pin = OMAP_MPUIO(3), |
| 61 | .power_pin = -1, |
| 62 | .switch_pin = -1, |
| 63 | }, |
| 64 | }; |
| 65 | |
| 66 | static struct omap_lcd_config palmte_lcd_config __initdata = { |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 67 | .ctrl_name = "internal", |
| 68 | }; |
| 69 | |
| 70 | static struct omap_board_config_kernel palmte_config[] = { |
| 71 | { OMAP_TAG_USB, &palmte_usb_config }, |
| 72 | { OMAP_TAG_MMC, &palmte_mmc_config }, |
| 73 | { OMAP_TAG_LCD, &palmte_lcd_config }, |
| 74 | }; |
| 75 | |
| 76 | static void __init omap_generic_init(void) |
| 77 | { |
| 78 | omap_board_config = palmte_config; |
| 79 | omap_board_config_size = ARRAY_SIZE(palmte_config); |
Tony Lindgren | 9b6553c | 2006-04-02 17:46:30 +0100 | [diff] [blame] | 80 | |
| 81 | platform_add_devices(devices, ARRAY_SIZE(devices)); |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 82 | } |
| 83 | |
| 84 | static void __init omap_generic_map_io(void) |
| 85 | { |
Tony Lindgren | 87bd63f | 2006-02-08 22:06:46 +0000 | [diff] [blame] | 86 | omap1_map_common_io(); |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 87 | } |
| 88 | |
| 89 | MACHINE_START(OMAP_PALMTE, "OMAP310 based Palm Tungsten E") |
Tony Lindgren | 3179a01 | 2005-11-10 14:26:48 +0000 | [diff] [blame] | 90 | .phys_io = 0xfff00000, |
| 91 | .io_pg_offst = ((0xfef00000) >> 18) & 0xfffc, |
| 92 | .boot_params = 0x10000100, |
| 93 | .map_io = omap_generic_map_io, |
| 94 | .init_irq = omap_generic_init_irq, |
| 95 | .init_machine = omap_generic_init, |
| 96 | .timer = &omap_timer, |
| 97 | MACHINE_END |