board-halibut.c 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /* linux/arch/arm/mach-msm/board-halibut.c
  2. *
  3. * Copyright (C) 2007 Google, Inc.
  4. * Author: Brian Swetland <swetland@google.com>
  5. *
  6. * This software is licensed under the terms of the GNU General Public
  7. * License version 2, as published by the Free Software Foundation, and
  8. * may be copied, distributed, and modified under those terms.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. *
  15. */
  16. #include <linux/kernel.h>
  17. #include <linux/init.h>
  18. #include <linux/platform_device.h>
  19. #include <linux/input.h>
  20. #include <linux/io.h>
  21. #include <linux/delay.h>
  22. #include <mach/hardware.h>
  23. #include <asm/mach-types.h>
  24. #include <asm/mach/arch.h>
  25. #include <asm/mach/map.h>
  26. #include <asm/mach/flash.h>
  27. #include <mach/board.h>
  28. #include <mach/msm_iomap.h>
  29. #include <linux/mtd/nand.h>
  30. #include <linux/mtd/partitions.h>
  31. #include "devices.h"
  32. static struct resource smc91x_resources[] = {
  33. [0] = {
  34. .start = 0x9C004300,
  35. .end = 0x9C004400,
  36. .flags = IORESOURCE_MEM,
  37. },
  38. [1] = {
  39. .start = MSM_GPIO_TO_INT(49),
  40. .end = MSM_GPIO_TO_INT(49),
  41. .flags = IORESOURCE_IRQ,
  42. },
  43. };
  44. static struct platform_device smc91x_device = {
  45. .name = "smc91x",
  46. .id = 0,
  47. .num_resources = ARRAY_SIZE(smc91x_resources),
  48. .resource = smc91x_resources,
  49. };
  50. static struct platform_device *devices[] __initdata = {
  51. &msm_device_uart3,
  52. &msm_device_smd,
  53. &msm_device_nand,
  54. &msm_device_hsusb,
  55. &msm_device_i2c,
  56. &smc91x_device,
  57. };
  58. extern struct sys_timer msm_timer;
  59. static void __init halibut_init_irq(void)
  60. {
  61. msm_init_irq();
  62. }
  63. static void __init halibut_init(void)
  64. {
  65. platform_add_devices(devices, ARRAY_SIZE(devices));
  66. }
  67. static void __init halibut_map_io(void)
  68. {
  69. msm_map_common_io();
  70. msm_clock_init();
  71. }
  72. MACHINE_START(HALIBUT, "Halibut Board (QCT SURF7200A)")
  73. .boot_params = 0x10000100,
  74. .map_io = halibut_map_io,
  75. .init_irq = halibut_init_irq,
  76. .init_machine = halibut_init,
  77. .timer = &msm_timer,
  78. MACHINE_END