2 * Hardware definitions for the Toshiba eseries PDAs
4 * Copyright (c) 2003 Ian Molton <spyro@f2s.com>
6 * This file is licensed under
7 * the terms of the GNU General Public License version 2. This program
8 * is licensed "as is" without any warranty of any kind, whether express
13 #include <linux/kernel.h>
14 #include <linux/init.h>
15 #include <linux/clk.h>
16 #include <linux/platform_device.h>
17 #include <linux/mfd/t7l66xb.h>
18 #include <linux/mtd/nand.h>
19 #include <linux/mtd/partitions.h>
21 #include <asm/setup.h>
22 #include <asm/mach/arch.h>
23 #include <asm/mach-types.h>
25 #include <mach/mfp-pxa25x.h>
26 #include <mach/pxa-regs.h>
27 #include <mach/hardware.h>
28 #include <mach/eseries-gpio.h>
29 #include <mach/pxafb.h>
31 #include <mach/irqs.h>
37 /* ------------------------ E400 LCD definitions ------------------------ */
39 static struct pxafb_mode_info e400_pxafb_mode_info = {
53 static struct pxafb_mach_info e400_pxafb_mach_info = {
54 .modes = &e400_pxafb_mode_info,
56 .lcd_conn = LCD_COLOR_TFT_16BPP,
58 .pxafb_backlight_power = NULL,
61 /* ------------------------ E400 MFP config ----------------------------- */
63 static unsigned long e400_pin_config[] __initdata = {
65 GPIO15_nCS_1, /* CS1 - Flash */
66 GPIO80_nCS_4, /* CS4 - TMIO */
77 GPIO19_GPIO, /* t7l66xb #PCLR */
78 GPIO45_GPIO, /* t7l66xb #SUSPEND (NOT BTUART!) */
81 GPIO0_GPIO | WAKEUP_ON_EDGE_RISE,
84 /* ---------------------------------------------------------------------- */
86 static struct mtd_partition partition_a = {
87 .name = "Internal NAND flash",
89 .size = MTDPART_SIZ_FULL,
92 static uint8_t scan_ff_pattern[] = { 0xff, 0xff };
94 static struct nand_bbt_descr e400_t7l66xb_nand_bbt = {
98 .pattern = scan_ff_pattern
101 static struct tmio_nand_data e400_t7l66xb_nand_config = {
103 .partition = &partition_a,
104 .badblock_pattern = &e400_t7l66xb_nand_bbt,
107 static struct t7l66xb_platform_data e400_t7l66xb_info = {
108 .irq_base = IRQ_BOARD_START,
109 .enable = &eseries_tmio_enable,
110 .suspend = &eseries_tmio_suspend,
111 .resume = &eseries_tmio_resume,
113 .nand_data = &e400_t7l66xb_nand_config,
116 static struct platform_device e400_t7l66xb_device = {
120 .platform_data = &e400_t7l66xb_info,
123 .resource = eseries_tmio_resources,
126 /* ---------------------------------------------------------- */
128 static struct platform_device *devices[] __initdata = {
129 &e400_t7l66xb_device,
132 static void __init e400_init(void)
134 pxa2xx_mfp_config(ARRAY_AND_SIZE(e400_pin_config));
135 /* Fixme - e400 may have a switched clock */
136 eseries_register_clks();
137 eseries_get_tmio_gpios();
138 set_pxa_fb_info(&e400_pxafb_mach_info);
139 platform_add_devices(devices, ARRAY_SIZE(devices));
140 pxa_set_udc_info(&e7xx_udc_mach_info);
143 MACHINE_START(E400, "Toshiba e400")
144 /* Maintainer: Ian Molton (spyro@f2s.com) */
145 .phys_io = 0x40000000,
146 .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
147 .boot_params = 0xa0000100,
148 .map_io = pxa_map_io,
149 .init_irq = pxa25x_init_irq,
150 .fixup = eseries_fixup,
151 .init_machine = e400_init,