]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blob - arch/arm/boot/dts/overlays/pisound-overlay.dts
BCM2708: Add core Device Tree support
[mirror_ubuntu-artful-kernel.git] / arch / arm / boot / dts / overlays / pisound-overlay.dts
1 /*
2 * pisound Linux kernel module.
3 * Copyright (C) 2016 Vilniaus Blokas UAB, http://blokas.io/pisound
4 *
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License
7 * as published by the Free Software Foundation; version 2 of the
8 * 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 Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 */
19
20 /dts-v1/;
21 /plugin/;
22
23 #include <dt-bindings/gpio/gpio.h>
24
25 / {
26 compatible = "brcm,bcm2708";
27
28 fragment@0 {
29 target = <&spi0>;
30 __overlay__ {
31 status = "okay";
32 };
33 };
34
35 fragment@1 {
36 target = <&spidev0>;
37 __overlay__ {
38 status = "disabled";
39 };
40 };
41
42 fragment@2 {
43 target = <&spidev1>;
44 __overlay__ {
45 status = "okay";
46 };
47 };
48
49 fragment@3 {
50 target = <&spi0>;
51 __overlay__ {
52 #address-cells = <1>;
53 #size-cells = <0>;
54
55 pisound_spi: pisound_spi@0{
56 compatible = "blokaslabs,pisound-spi";
57 reg = <0>;
58 pinctrl-names = "default";
59 pinctrl-0 = <&spi0_pins>;
60 spi-max-frequency = <1000000>;
61 };
62 };
63 };
64
65 fragment@4 {
66 target-path = "/";
67 __overlay__ {
68 pcm5102a-codec {
69 #sound-dai-cells = <0>;
70 compatible = "ti,pcm5102a";
71 status = "okay";
72 };
73 };
74 };
75
76 fragment@5 {
77 target = <&sound>;
78 __overlay__ {
79 compatible = "blokaslabs,pisound";
80 i2s-controller = <&i2s>;
81 status = "okay";
82
83 pinctrl-0 = <&pisound_button_pins>;
84
85 osr-gpios =
86 <&gpio 13 GPIO_ACTIVE_HIGH>,
87 <&gpio 26 GPIO_ACTIVE_HIGH>,
88 <&gpio 16 GPIO_ACTIVE_HIGH>;
89
90 reset-gpios =
91 <&gpio 12 GPIO_ACTIVE_HIGH>,
92 <&gpio 24 GPIO_ACTIVE_HIGH>;
93
94 data_available-gpios = <&gpio 25 GPIO_ACTIVE_HIGH>;
95
96 button-gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
97 };
98 };
99
100 fragment@6 {
101 target = <&gpio>;
102 __overlay__ {
103 pinctrl-names = "default";
104 pinctrl-0 = <&pisound_button_pins>;
105
106 pisound_button_pins: pisound_button_pins {
107 brcm,pins = <17>;
108 brcm,function = <0>; // Input
109 brcm,pull = <2>; // Pull-Up
110 };
111 };
112 };
113
114 fragment@7 {
115 target = <&i2s>;
116 __overlay__ {
117 status = "okay";
118 };
119 };
120 };