113-dt-sun7i-add-lradc.patch 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. From a735a9b354ebc1a17b648ef8c3482c71fdbf40da Mon Sep 17 00:00:00 2001
  2. From: Hans de Goede <hdegoede@redhat.com>
  3. Date: Wed, 1 Jan 2014 20:26:21 +0100
  4. Subject: [PATCH] ARM: dts: sun7i: Add lradc node
  5. Signed-off-by: Hans de Goede <hdegoede@redhat.com>
  6. ---
  7. arch/arm/boot/dts/sun7i-a20-olinuxino-micro.dts | 59 ++++++++++++++++++++++++-
  8. arch/arm/boot/dts/sun7i-a20.dtsi | 7 +++
  9. 2 files changed, 64 insertions(+), 2 deletions(-)
  10. --- a/arch/arm/boot/dts/sun7i-a20-olinuxino-micro.dts
  11. +++ b/arch/arm/boot/dts/sun7i-a20-olinuxino-micro.dts
  12. @@ -12,8 +12,9 @@
  13. */
  14. /dts-v1/;
  15. -/include/ "sun7i-a20.dtsi"
  16. -/include/ "sunxi-common-regulators.dtsi"
  17. +#include "sun7i-a20.dtsi"
  18. +#include "sunxi-common-regulators.dtsi"
  19. +#include <dt-bindings/input/input.h>
  20. / {
  21. model = "Olimex A20-Olinuxino Micro";
  22. @@ -100,6 +101,60 @@
  23. };
  24. };
  25. + lradc: lradc@01c22800 {
  26. + vref-supply = <&reg_vcc3v0>;
  27. + status = "okay";
  28. +
  29. + button@191 {
  30. + label = "Volume Up";
  31. + linux,code = <KEY_VOLUMEUP>;
  32. + channel = <0>;
  33. + voltage = <191274>;
  34. + };
  35. +
  36. + button@392 {
  37. + label = "Volume Down";
  38. + linux,code = <KEY_VOLUMEDOWN>;
  39. + channel = <0>;
  40. + voltage = <392644>;
  41. + };
  42. +
  43. + button@601 {
  44. + label = "Menu";
  45. + linux,code = <KEY_MENU>;
  46. + channel = <0>;
  47. + voltage = <601151>;
  48. + };
  49. +
  50. + button@795 {
  51. + label = "Search";
  52. + linux,code = <KEY_SEARCH>;
  53. + channel = <0>;
  54. + voltage = <795090>;
  55. + };
  56. +
  57. + button@987 {
  58. + label = "Home";
  59. + linux,code = <KEY_HOMEPAGE>;
  60. + channel = <0>;
  61. + voltage = <987387>;
  62. + };
  63. +
  64. + button@1184 {
  65. + label = "Esc";
  66. + linux,code = <KEY_ESC>;
  67. + channel = <0>;
  68. + voltage = <1184678>;
  69. + };
  70. +
  71. + button@1398 {
  72. + label = "Enter";
  73. + linux,code = <KEY_ENTER>;
  74. + channel = <0>;
  75. + voltage = <1398804>;
  76. + };
  77. + };
  78. +
  79. uart0: serial@01c28000 {
  80. pinctrl-names = "default";
  81. pinctrl-0 = <&uart0_pins_a>;
  82. --- a/arch/arm/boot/dts/sun7i-a20.dtsi
  83. +++ b/arch/arm/boot/dts/sun7i-a20.dtsi
  84. @@ -911,6 +911,13 @@
  85. status = "disabled";
  86. };
  87. + lradc: lradc@01c22800 {
  88. + compatible = "allwinner,sun4i-a10-lradc-keys";
  89. + reg = <0x01c22800 0x100>;
  90. + interrupts = <0 31 4>;
  91. + status = "disabled";
  92. + };
  93. +
  94. sid: eeprom@01c23800 {
  95. compatible = "allwinner,sun7i-a20-sid";
  96. reg = <0x01c23800 0x200>;