eseries.c 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. /*
  2. * Hardware definitions for the Toshiba eseries PDAs
  3. *
  4. * Copyright (c) 2003 Ian Molton <spyro@f2s.com>
  5. *
  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
  9. * or implied.
  10. *
  11. */
  12. #include <linux/kernel.h>
  13. #include <linux/init.h>
  14. #include <asm/setup.h>
  15. #include <asm/mach/arch.h>
  16. #include <asm/mach-types.h>
  17. #include <mach/mfp-pxa25x.h>
  18. #include <mach/hardware.h>
  19. #include "generic.h"
  20. static unsigned long e740_pin_config[] __initdata = {
  21. /* Chip selects */
  22. GPIO15_nCS_1, /* CS1 - Flash */
  23. GPIO79_nCS_3, /* CS3 - IMAGEON */
  24. GPIO80_nCS_4, /* CS4 - TMIO */
  25. /* Clocks */
  26. GPIO12_32KHz,
  27. /* BTUART */
  28. GPIO42_BTUART_RXD,
  29. GPIO43_BTUART_TXD,
  30. GPIO44_BTUART_CTS,
  31. GPIO45_GPIO, /* Used by TMIO for #SUSPEND */
  32. /* PC Card */
  33. GPIO8_GPIO, /* CD0 */
  34. GPIO44_GPIO, /* CD1 */
  35. GPIO11_GPIO, /* IRQ0 */
  36. GPIO6_GPIO, /* IRQ1 */
  37. GPIO27_GPIO, /* RST0 */
  38. GPIO24_GPIO, /* RST1 */
  39. GPIO20_GPIO, /* PWR0 */
  40. GPIO23_GPIO, /* PWR1 */
  41. GPIO48_nPOE,
  42. GPIO49_nPWE,
  43. GPIO50_nPIOR,
  44. GPIO51_nPIOW,
  45. GPIO52_nPCE_1,
  46. GPIO53_nPCE_2,
  47. GPIO54_nPSKTSEL,
  48. GPIO55_nPREG,
  49. GPIO56_nPWAIT,
  50. GPIO57_nIOIS16,
  51. /* wakeup */
  52. GPIO0_GPIO | WAKEUP_ON_EDGE_RISE,
  53. };
  54. static unsigned long e400_pin_config[] __initdata = {
  55. /* Chip selects */
  56. GPIO15_nCS_1, /* CS1 - Flash */
  57. GPIO80_nCS_4, /* CS4 - TMIO */
  58. /* Clocks */
  59. GPIO12_32KHz,
  60. /* BTUART */
  61. GPIO42_BTUART_RXD,
  62. GPIO43_BTUART_TXD,
  63. GPIO44_BTUART_CTS,
  64. GPIO45_GPIO, /* Used by TMIO for #SUSPEND */
  65. /* wakeup */
  66. GPIO0_GPIO | WAKEUP_ON_EDGE_RISE,
  67. };
  68. /* Only e800 has 128MB RAM */
  69. static void __init eseries_fixup(struct machine_desc *desc,
  70. struct tag *tags, char **cmdline, struct meminfo *mi)
  71. {
  72. mi->nr_banks=1;
  73. mi->bank[0].start = 0xa0000000;
  74. mi->bank[0].node = 0;
  75. if (machine_is_e800())
  76. mi->bank[0].size = (128*1024*1024);
  77. else
  78. mi->bank[0].size = (64*1024*1024);
  79. }
  80. static void __init e740_init(void)
  81. {
  82. pxa2xx_mfp_config(ARRAY_AND_SIZE(e740_pin_config));
  83. }
  84. static void __init e400_init(void)
  85. {
  86. pxa2xx_mfp_config(ARRAY_AND_SIZE(e400_pin_config));
  87. }
  88. /* e-series machine definitions */
  89. #ifdef CONFIG_MACH_E330
  90. MACHINE_START(E330, "Toshiba e330")
  91. /* Maintainer: Ian Molton (spyro@f2s.com) */
  92. .phys_io = 0x40000000,
  93. .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
  94. .boot_params = 0xa0000100,
  95. .map_io = pxa_map_io,
  96. .init_irq = pxa25x_init_irq,
  97. .fixup = eseries_fixup,
  98. .timer = &pxa_timer,
  99. MACHINE_END
  100. #endif
  101. #ifdef CONFIG_MACH_E350
  102. MACHINE_START(E350, "Toshiba e350")
  103. /* Maintainer: Ian Molton (spyro@f2s.com) */
  104. .phys_io = 0x40000000,
  105. .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
  106. .boot_params = 0xa0000100,
  107. .map_io = pxa_map_io,
  108. .init_irq = pxa25x_init_irq,
  109. .fixup = eseries_fixup,
  110. .timer = &pxa_timer,
  111. MACHINE_END
  112. #endif
  113. #ifdef CONFIG_MACH_E740
  114. MACHINE_START(E740, "Toshiba e740")
  115. /* Maintainer: Ian Molton (spyro@f2s.com) */
  116. .phys_io = 0x40000000,
  117. .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
  118. .boot_params = 0xa0000100,
  119. .map_io = pxa_map_io,
  120. .init_irq = pxa25x_init_irq,
  121. .fixup = eseries_fixup,
  122. .init_machine = e740_init,
  123. .timer = &pxa_timer,
  124. MACHINE_END
  125. #endif
  126. #ifdef CONFIG_MACH_E750
  127. MACHINE_START(E750, "Toshiba e750")
  128. /* Maintainer: Ian Molton (spyro@f2s.com) */
  129. .phys_io = 0x40000000,
  130. .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
  131. .boot_params = 0xa0000100,
  132. .map_io = pxa_map_io,
  133. .init_irq = pxa25x_init_irq,
  134. .fixup = eseries_fixup,
  135. .timer = &pxa_timer,
  136. MACHINE_END
  137. #endif
  138. #ifdef CONFIG_MACH_E400
  139. MACHINE_START(E400, "Toshiba e400")
  140. /* Maintainer: Ian Molton (spyro@f2s.com) */
  141. .phys_io = 0x40000000,
  142. .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
  143. .boot_params = 0xa0000100,
  144. .map_io = pxa_map_io,
  145. .init_irq = pxa25x_init_irq,
  146. .fixup = eseries_fixup,
  147. .init_machine = e400_init,
  148. .timer = &pxa_timer,
  149. MACHINE_END
  150. #endif
  151. #ifdef CONFIG_MACH_E800
  152. MACHINE_START(E800, "Toshiba e800")
  153. /* Maintainer: Ian Molton (spyro@f2s.com) */
  154. .phys_io = 0x40000000,
  155. .io_pg_offst = (io_p2v(0x40000000) >> 18) & 0xfffc,
  156. .boot_params = 0xa0000100,
  157. .map_io = pxa_map_io,
  158. .init_irq = pxa25x_init_irq,
  159. .fixup = eseries_fixup,
  160. .timer = &pxa_timer,
  161. MACHINE_END
  162. #endif