1/*
2 * Device Tree file for Freescale LS1012A QDS Board.
3 *
4 * Copyright 2016 Freescale Semiconductor, Inc.
5 *
6 * This file is dual-licensed: you can use it either under the terms
7 * of the GPLv2 or the X11 license, at your option. Note that this dual
8 * licensing only applies to this file, and not this project as a
9 * whole.
10 *
11 *  a) This library is free software; you can redistribute it and/or
12 *     modify it under the terms of the GNU General Public License as
13 *     published by the Free Software Foundation; either version 2 of the
14 *     License, or (at your option) any later version.
15 *
16 *     This library is distributed in the hope that it will be useful,
17 *     but WITHOUT ANY WARRANTY; without even the implied warranty of
18 *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19 *     GNU General Public License for more details.
20 *
21 * Or, alternatively,
22 *
23 *  b) Permission is hereby granted, free of charge, to any person
24 *     obtaining a copy of this software and associated documentation
25 *     files (the "Software"), to deal in the Software without
26 *     restriction, including without limitation the rights to use,
27 *     copy, modify, merge, publish, distribute, sublicense, and/or
28 *     sell copies of the Software, and to permit persons to whom the
29 *     Software is furnished to do so, subject to the following
30 *     conditions:
31 *
32 *     The above copyright notice and this permission notice shall be
33 *     included in all copies or substantial portions of the Software.
34 *
35 *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
36 *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
37 *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
38 *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
39 *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
40 *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
41 *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
42 *     OTHER DEALINGS IN THE SOFTWARE.
43 */
44/dts-v1/;
45
46#include "fsl-ls1012a.dtsi"
47
48/ {
49	model = "LS1012A QDS Board";
50	compatible = "fsl,ls1012a-qds", "fsl,ls1012a";
51
52	sys_mclk: clock-mclk {
53		compatible = "fixed-clock";
54		#clock-cells = <0>;
55		clock-frequency = <24576000>;
56	};
57
58	reg_3p3v: regulator-3p3v {
59		compatible = "regulator-fixed";
60		regulator-name = "3P3V";
61		regulator-min-microvolt = <3300000>;
62		regulator-max-microvolt = <3300000>;
63		regulator-always-on;
64	};
65
66	sound {
67		compatible = "simple-audio-card";
68		simple-audio-card,format = "i2s";
69		simple-audio-card,widgets =
70			"Microphone", "Microphone Jack",
71			"Headphone", "Headphone Jack",
72			"Speaker", "Speaker Ext",
73			"Line", "Line In Jack";
74		simple-audio-card,routing =
75			"MIC_IN", "Microphone Jack",
76			"Microphone Jack", "Mic Bias",
77			"LINE_IN", "Line In Jack",
78			"Headphone Jack", "HP_OUT",
79			"Speaker Ext", "LINE_OUT";
80
81		simple-audio-card,cpu {
82			sound-dai = <&sai2>;
83			frame-master;
84			bitclock-master;
85		};
86
87		simple-audio-card,codec {
88			sound-dai = <&codec>;
89			frame-master;
90			bitclock-master;
91			system-clock-frequency = <24576000>;
92		};
93	};
94};
95
96&dspi {
97	bus-num = <0>;
98	status = "okay";
99
100	flash@0 {
101		#address-cells = <1>;
102		#size-cells = <1>;
103		compatible = "n25q128a11", "jedec,spi-nor";
104		reg = <0>;
105		spi-max-frequency = <10000000>;
106	};
107
108	flash@1 {
109		#address-cells = <1>;
110		#size-cells = <1>;
111		compatible = "sst25wf040b", "jedec,spi-nor";
112		spi-cpol;
113		spi-cpha;
114		reg = <1>;
115		spi-max-frequency = <10000000>;
116	};
117
118	flash@2 {
119		#address-cells = <1>;
120		#size-cells = <1>;
121		compatible = "en25s64", "jedec,spi-nor";
122		spi-cpol;
123		spi-cpha;
124		reg = <2>;
125		spi-max-frequency = <10000000>;
126	};
127};
128
129&duart0 {
130	status = "okay";
131};
132
133&esdhc0 {
134	status = "okay";
135};
136
137&esdhc1 {
138	status = "okay";
139};
140
141&i2c0 {
142	status = "okay";
143
144	pca9547@77 {
145		compatible = "nxp,pca9547";
146		reg = <0x77>;
147		#address-cells = <1>;
148		#size-cells = <0>;
149
150		i2c@4 {
151			#address-cells = <1>;
152			#size-cells = <0>;
153			reg = <0x4>;
154
155			codec: sgtl5000@a {
156				#sound-dai-cells = <0>;
157				compatible = "fsl,sgtl5000";
158				reg = <0xa>;
159				VDDA-supply = <&reg_3p3v>;
160				VDDIO-supply = <&reg_3p3v>;
161				clocks = <&sys_mclk>;
162			};
163		};
164	};
165};
166
167&sai2 {
168	status = "okay";
169};
170
171&sata {
172	status = "okay";
173};
174