connectionSignalSlot.c 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. /*
  2. * KZM-A9-GT board support
  3. *
  4. * Copyright (C) 2012 Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License as published by
  8. * the Free Software Foundation; version 2 of the License.
  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. * You should have received a copy of the GNU General Public License
  16. * along with this program; if not, write to the Free Software
  17. * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  18. */
  19. #include <linux/delay.h>
  20. #include <linux/gpio.h>
  21. #include <linux/gpio_keys.h>
  22. #include <linux/io.h>
  23. #include <linux/irq.h>
  24. #include <linux/i2c.h>
  25. #include <linux/i2c/pcf857x.h>
  26. #include <linux/input.h>
  27. #include <linux/mmc/host.h>
  28. #include <linux/mmc/sh_mmcif.h>
  29. #include <linux/mmc/sh_mobile_sdhi.h>
  30. #include <linux/mfd/tmio.h>
  31. #include <linux/platform_device.h>
  32. #include <linux/regulator/fixed.h>
  33. #include <linux/regulator/machine.h>
  34. #include <linux/smsc911x.h>
  35. #include <linux/usb/r8a66597.h>
  36. #include <linux/usb/renesas_usbhs.h>
  37. #include <linux/videodev2.h>
  38. #include <sound/sh_fsi.h>
  39. #include <sound/simple_card.h>
  40. #include <mach/irqs.h>
  41. #include <mach/sh73a0.h>
  42. #include <mach/common.h>
  43. #include <asm/hardware/cache-l2x0.h>
  44. #include <asm/hardware/gic.h>
  45. #include <asm/mach-types.h>
  46. #include <asm/mach/arch.h>
  47. #include <video/sh_mobile_lcdc.h>
  48. /*
  49. * external GPIO
  50. */
  51. #define GPIO_PCF8575_BASE (GPIO_NR)
  52. #define GPIO_PCF8575_PORT10 (GPIO_NR + 8)
  53. #define GPIO_PCF8575_PORT11 (GPIO_NR + 9)
  54. #define GPIO_PCF8575_PORT12 (GPIO_NR + 10)
  55. #define GPIO_PCF8575_PORT13 (GPIO_NR + 11)
  56. #define GPIO_PCF8575_PORT14 (GPIO_NR + 12)
  57. #define GPIO_PCF8575_PORT15 (GPIO_NR + 13)
  58. #define GPIO_PCF8575_PORT16 (GPIO_NR + 14)
  59. /* Dummy supplies, where voltage doesn't matter */
  60. static struct regulator_consumer_supply dummy_supplies[] = {
  61. REGULATOR_SUPPLY("vddvario", "smsc911x"),
  62. REGULATOR_SUPPLY("vdd33a", "smsc911x"),
  63. };
  64. /*
  65. * FSI-AK4648
  66. *
  67. * this command is required when playback.
  68. *
  69. * # amixer set "LINEOUT Mixer DACL" on
  70. */
  71. /* SMSC 9221 */
  72. static struct resource smsc9221_resources[] = {
  73. [0] = {
  74. .start = 0x10000000, /* CS4 */
  75. .end = 0x100000ff,
  76. .flags = IORESOURCE_MEM,
  77. },
  78. [1] = {
  79. .start = intcs_evt2irq(0x260), /* IRQ3 */
  80. .flags = IORESOURCE_IRQ,
  81. },
  82. };
  83. static struct smsc911x_platform_config smsc9221_platdata = {
  84. .flags = SMSC911X_USE_32BIT | SMSC911X_SAVE_MAC_ADDRESS,
  85. .phy_interface = PHY_INTERFACE_MODE_MII,
  86. .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW,
  87. .irq_type = SMSC911X_IRQ_TYPE_PUSH_PULL,
  88. };
  89. static struct platform_device smsc_device = {
  90. .name = "smsc911x",