board-m3-skt.c 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. /*
  2. *
  3. * arch/arm/mach-meson/meson.c
  4. *
  5. * Copyright (C) 2010 AMLOGIC, INC.
  6. *
  7. * License terms: GNU General Public License (GPL) version 2
  8. * Platform machine definition.
  9. */
  10. #include <linux/kernel.h>
  11. #include <linux/init.h>
  12. #include <linux/mm.h>
  13. #include <linux/sched.h>
  14. #include <linux/interrupt.h>
  15. #include <linux/ioport.h>
  16. #include <linux/platform_device.h>
  17. #include <linux/io.h>
  18. #include <linux/dma-mapping.h>
  19. #include <linux/mtd/mtd.h>
  20. #include <linux/mtd/nand.h>
  21. #include <linux/mtd/nand_ecc.h>
  22. #include <linux/mtd/partitions.h>
  23. #include <linux/device.h>
  24. #include <linux/spi/flash.h>
  25. #include <linux/i2c.h>
  26. #include <linux/delay.h>
  27. #include <linux/clk.h>
  28. #include <asm/mach-types.h>
  29. #include <asm/setup.h>
  30. #include <asm/memory.h>
  31. #include <plat/platform.h>
  32. #include <plat/plat_dev.h>
  33. #include <plat/platform_data.h>
  34. #include <plat/lm.h>
  35. #include <plat/regops.h>
  36. #include <mach/am_regs.h>
  37. #include "board-m3-ref.h"
  38. #include <mach/map.h>
  39. #include <mach/i2c_aml.h>
  40. #include <mach/usbclock.h>
  41. #include "common-data.h"
  42. #if 0
  43. static pinmux_item_t uart_pins[]={
  44. {
  45. .reg=PINMUX_REG(AO),
  46. .clrmask=3<<16,
  47. .setmask=3<<11
  48. },
  49. PINMUX_END_ITEM
  50. };
  51. static pinmux_set_t aml_uart_ao={
  52. .chip_select=NULL,
  53. .pinmux=&uart_pins[0]
  54. };
  55. static struct aml_uart_platform __initdata aml_uart_plat = {
  56. .uart_line[0] = UART_AO,
  57. .uart_line[1] = UART_A,
  58. .uart_line[2] = UART_B,
  59. .uart_line[3] = UART_C,
  60. .pinmux_uart[0] = (void*)&aml_uart_ao,
  61. .pinmux_uart[1] = NULL,
  62. .pinmux_uart[2] = NULL,
  63. .pinmux_uart[3] = NULL,
  64. };
  65. static struct platform_device aml_uart_device = {
  66. .name = "mesonuart",
  67. .id = -1,
  68. .num_resources = 0,
  69. .resource = NULL,
  70. .dev = {
  71. .platform_data = &aml_uart_plat,
  72. },
  73. };
  74. #endif
  75. static __init void meson_init_machine(void)
  76. {
  77. ///platform_device_register(&aml_uart_device);
  78. /// platform_add_devices(platform_devs, ARRAY_SIZE(platform_devs));
  79. }
  80. MACHINE_START(M3_SKT, "Meson 3 socket board")
  81. .boot_params = BOOT_PARAMS_OFFSET,
  82. .map_io = meson_map_io,
  83. .init_irq = meson_init_irq,
  84. .timer = &meson_sys_timer,
  85. .init_machine = meson_init_machine,
  86. .fixup = meson_fixup,
  87. .video_start = RESERVED_MEM_START,
  88. .video_end = RESERVED_MEM_END,
  89. MACHINE_END