Linux Audio

Check our new training course

Loading...
v5.4
  1// SPDX-License-Identifier: GPL-2.0
  2/*
  3 * Device Tree Source for the KZM-A9-GT board
  4 *
  5 * Copyright (C) 2012 Horms Solutions Ltd.
  6 *
  7 * Based on sh73a0-kzm9g.dts
  8 * Copyright (C) 2012 Renesas Solutions Corp.
 
 
 
 
  9 */
 10
 11/dts-v1/;
 12#include "sh73a0.dtsi"
 13#include <dt-bindings/gpio/gpio.h>
 14#include <dt-bindings/input/input.h>
 15#include <dt-bindings/interrupt-controller/irq.h>
 16
 17/ {
 18	model = "KZM-A9-GT";
 19	compatible = "renesas,kzm9g", "renesas,sh73a0";
 20
 21	aliases {
 22		serial0 = &scifa4;
 23	};
 24
 25	cpus {
 26		cpu@0 {
 27			cpu0-supply = <&vdd_dvfs>;
 28			operating-points = <
 29				/* kHz  uV */
 30				1196000 1315000
 31				 598000 1175000
 32				 398667 1065000
 33			>;
 34			voltage-tolerance = <1>; /* 1% */
 35		};
 36	};
 37
 38	chosen {
 39		bootargs = "root=/dev/nfs ip=on ignore_loglevel rw";
 40		stdout-path = "serial0:115200n8";
 41	};
 42
 43	memory@40000000 {
 44		device_type = "memory";
 45		reg = <0x40000000 0x20000000>;
 46	};
 47
 48	reg_1p8v: regulator-1p8v {
 49		compatible = "regulator-fixed";
 50		regulator-name = "fixed-1.8V";
 51		regulator-min-microvolt = <1800000>;
 52		regulator-max-microvolt = <1800000>;
 53		regulator-always-on;
 54		regulator-boot-on;
 55	};
 56
 57	reg_3p3v: regulator-3p3v {
 58		compatible = "regulator-fixed";
 59		regulator-name = "fixed-3.3V";
 60		regulator-min-microvolt = <3300000>;
 61		regulator-max-microvolt = <3300000>;
 62		regulator-always-on;
 63		regulator-boot-on;
 64	};
 65
 66	vmmc_sdhi0: regulator-vmmc-sdhi0 {
 67		compatible = "regulator-fixed";
 68		regulator-name = "SDHI0 Vcc";
 69		regulator-min-microvolt = <3300000>;
 70		regulator-max-microvolt = <3300000>;
 71		gpio = <&pfc 15 GPIO_ACTIVE_HIGH>;
 72		enable-active-high;
 73	};
 74
 75	vmmc_sdhi2: regulator-vmmc-sdhi2 {
 76		compatible = "regulator-fixed";
 77		regulator-name = "SDHI2 Vcc";
 78		regulator-min-microvolt = <3300000>;
 79		regulator-max-microvolt = <3300000>;
 80		gpio = <&pfc 14 GPIO_ACTIVE_HIGH>;
 81		enable-active-high;
 82	};
 83
 84	leds {
 85		compatible = "gpio-leds";
 86		led1 {
 87			gpios = <&pfc 20 GPIO_ACTIVE_LOW>;
 88			label = "LED1";
 89		};
 90		led2 {
 91			gpios = <&pfc 21 GPIO_ACTIVE_LOW>;
 92			label = "LED2";
 93		};
 94		led3 {
 95			gpios = <&pfc 22 GPIO_ACTIVE_LOW>;
 96			label = "LED3";
 97		};
 98		led4 {
 99			gpios = <&pfc 23 GPIO_ACTIVE_LOW>;
100			label = "LED4";
101		};
102	};
103
104	keyboard {
105		compatible = "gpio-keys";
106
107		back-key {
108			gpios = <&pcf8575 8 GPIO_ACTIVE_LOW>;
109			linux,code = <KEY_BACK>;
110			label = "SW3";
111		};
112
113		right-key {
114			gpios = <&pcf8575 9 GPIO_ACTIVE_LOW>;
115			linux,code = <KEY_RIGHT>;
116			label = "SW2-R";
117		};
118
119		left-key {
120			gpios = <&pcf8575 10 GPIO_ACTIVE_LOW>;
121			linux,code = <KEY_LEFT>;
122			label = "SW2-L";
123		};
124
125		enter-key {
126			gpios = <&pcf8575 11 GPIO_ACTIVE_LOW>;
127			linux,code = <KEY_ENTER>;
128			label = "SW2-P";
129		};
130
131		up-key {
132			gpios = <&pcf8575 12 GPIO_ACTIVE_LOW>;
133			linux,code = <KEY_UP>;
134			label = "SW2-U";
135		};
136
137		down-key {
138			gpios = <&pcf8575 13 GPIO_ACTIVE_LOW>;
139			linux,code = <KEY_DOWN>;
140			label = "SW2-D";
141		};
142
143		home-key {
144			gpios = <&pcf8575 14 GPIO_ACTIVE_LOW>;
145			linux,code = <KEY_HOME>;
146			label = "SW1";
147			wakeup-source;
148		};
149
150		wakeup-key {
151			gpios = <&pfc 159 GPIO_ACTIVE_LOW>;
152			linux,code = <KEY_WAKEUP>;
153			label = "NMI";
154			wakeup-source;
155		};
156	};
157
158	sound {
159		compatible = "simple-audio-card";
160		simple-audio-card,format = "left_j";
161		simple-audio-card,cpu {
162			sound-dai = <&sh_fsi2 0>;
163		};
164		simple-audio-card,codec {
165			sound-dai = <&ak4648>;
166			bitclock-master;
167			frame-master;
168			system-clock-frequency = <11289600>;
169		};
170	};
171};
172
173&bsc {
174	ethernet@10000000 {
175		compatible = "smsc,lan9220", "smsc,lan9115";
176		reg = <0x10000000 0x100>;
177		phy-mode = "mii";
178		interrupt-parent = <&irqpin0>;
179		interrupts = <3 IRQ_TYPE_EDGE_FALLING>;
180		reg-io-width = <4>;
181		smsc,irq-push-pull;
182		smsc,save-mac-address;
183		vddvario-supply = <&reg_1p8v>;
184		vdd33a-supply = <&reg_3p3v>;
185	};
186};
187
188&cmt1 {
189	status = "okay";
190};
191
192&extal2_clk {
193	clock-frequency = <48000000>;
194};
195
196&i2c0 {
197	status = "okay";
198
199	compass@c {
200		compatible = "asahi-kasei,ak8975";
201		reg = <0x0c>;
202		interrupt-parent = <&irqpin3>;
203		interrupts = <4 IRQ_TYPE_EDGE_FALLING>;
204	};
205
206	ak4648: codec@12 {
207		compatible = "asahi-kasei,ak4648";
208		reg = <0x12>;
209		#sound-dai-cells = <0>;
210	};
211
212	accelerometer@1d {
213		compatible = "adi,adxl345";
214		reg = <0x1d>;
215		interrupt-parent = <&irqpin3>;
216		interrupts = <2 IRQ_TYPE_LEVEL_HIGH>,
217			     <3 IRQ_TYPE_LEVEL_HIGH>;
218	};
219
220	rtc@32 {
221		compatible = "ricoh,r2025sd";
222		reg = <0x32>;
223	};
224
225	as3711@40 {
226		compatible = "ams,as3711";
227		reg = <0x40>;
228
229		regulators {
230			vdd_dvfs: sd1 {
231				regulator-name = "1.315V CPU";
232				regulator-min-microvolt = <1050000>;
233				regulator-max-microvolt = <1350000>;
234				regulator-always-on;
235				regulator-boot-on;
236			};
237			sd2 {
238				regulator-name = "1.8V";
239				regulator-min-microvolt = <1800000>;
240				regulator-max-microvolt = <1800000>;
241				regulator-always-on;
242				regulator-boot-on;
243			};
244			sd4 {
245				regulator-name = "1.215V";
246				regulator-min-microvolt = <1215000>;
247				regulator-max-microvolt = <1235000>;
248				regulator-always-on;
249				regulator-boot-on;
250			};
251			ldo2 {
252				regulator-name = "2.8V CPU";
253				regulator-min-microvolt = <2800000>;
254				regulator-max-microvolt = <2800000>;
255				regulator-always-on;
256				regulator-boot-on;
257			};
258			ldo3 {
259				regulator-name = "3.0V CPU";
260				regulator-min-microvolt = <3000000>;
261				regulator-max-microvolt = <3000000>;
262				regulator-always-on;
263				regulator-boot-on;
264			};
265			ldo4 {
266				regulator-name = "2.8V";
267				regulator-min-microvolt = <2800000>;
268				regulator-max-microvolt = <2800000>;
269				regulator-always-on;
270				regulator-boot-on;
271			};
272			ldo5 {
273				regulator-name = "2.8V #2";
274				regulator-min-microvolt = <2800000>;
275				regulator-max-microvolt = <2800000>;
276				regulator-always-on;
277				regulator-boot-on;
278			};
279			ldo7 {
280				regulator-name = "1.15V CPU";
281				regulator-min-microvolt = <1150000>;
282				regulator-max-microvolt = <1150000>;
283				regulator-always-on;
284				regulator-boot-on;
285			};
286			ldo8 {
287				regulator-name = "1.15V CPU #2";
288				regulator-min-microvolt = <1150000>;
289				regulator-max-microvolt = <1150000>;
290				regulator-always-on;
291				regulator-boot-on;
292			};
293		};
294	};
295};
296
297&i2c1 {
298	status = "okay";
299
300	touchscreen@55 {
301		compatible = "sitronix,st1232";
302		reg = <0x55>;
303		interrupt-parent = <&irqpin1>;
304		interrupts = <0 IRQ_TYPE_EDGE_FALLING>;
305	};
306};
307
308&i2c3 {
309	pinctrl-0 = <&i2c3_pins>;
310	pinctrl-names = "default";
311	status = "okay";
312
313	pcf8575: gpio@20 {
314		compatible = "nxp,pcf8575";
315		reg = <0x20>;
316		interrupt-parent = <&irqpin2>;
317		interrupts = <3 IRQ_TYPE_EDGE_FALLING>;
318		gpio-controller;
319		#gpio-cells = <2>;
320		interrupt-controller;
321		#interrupt-cells = <2>;
322	};
323};
324
325&mmcif {
326	pinctrl-0 = <&mmcif_pins>;
327	pinctrl-names = "default";
328
329	bus-width = <8>;
330	vmmc-supply = <&reg_1p8v>;
331	status = "okay";
332};
333
334&pfc {
335	i2c3_pins: i2c3 {
336		groups = "i2c3_1";
337		function = "i2c3";
338	};
339
340	mmcif_pins: mmc {
341		mux {
342			groups = "mmc0_data8_0", "mmc0_ctrl_0";
343			function = "mmc0";
344		};
345		cfg {
346			groups = "mmc0_data8_0";
347			pins = "PORT279";
348			bias-pull-up;
349		};
350	};
351
352	scifa4_pins: scifa4 {
353		groups = "scifa4_data", "scifa4_ctrl";
354		function = "scifa4";
355	};
356
357	sdhi0_pins: sd0 {
358		groups = "sdhi0_data4", "sdhi0_ctrl", "sdhi0_cd", "sdhi0_wp";
359		function = "sdhi0";
360	};
361
362	sdhi2_pins: sd2 {
363		groups = "sdhi2_data4", "sdhi2_ctrl";
364		function = "sdhi2";
365	};
366
367	fsia_pins: sounda {
368		groups = "fsia_mclk_in", "fsia_sclk_in",
369			 "fsia_data_in", "fsia_data_out";
370		function = "fsia";
371	};
372};
373
374&scifa4 {
375	pinctrl-0 = <&scifa4_pins>;
376	pinctrl-names = "default";
377
378	uart-has-rtscts;
379	status = "okay";
380};
381
382&sdhi0 {
383	pinctrl-0 = <&sdhi0_pins>;
384	pinctrl-names = "default";
385
386	vmmc-supply = <&vmmc_sdhi0>;
387	bus-width = <4>;
388	status = "okay";
389};
390
391&sdhi2 {
392	pinctrl-0 = <&sdhi2_pins>;
393	pinctrl-names = "default";
394
395	vmmc-supply = <&vmmc_sdhi2>;
396	bus-width = <4>;
397	broken-cd;
398	status = "okay";
399};
400
401&sh_fsi2 {
402	pinctrl-0 = <&fsia_pins>;
403	pinctrl-names = "default";
404
405	status = "okay";
406};
v4.6
 
  1/*
  2 * Device Tree Source for the KZM-A9-GT board
  3 *
  4 * Copyright (C) 2012 Horms Solutions Ltd.
  5 *
  6 * Based on sh73a0-kzm9g.dts
  7 * Copyright (C) 2012 Renesas Solutions Corp.
  8 *
  9 * This file is licensed under the terms of the GNU General Public License
 10 * version 2.  This program is licensed "as is" without any warranty of any
 11 * kind, whether express or implied.
 12 */
 13
 14/dts-v1/;
 15#include "sh73a0.dtsi"
 16#include <dt-bindings/gpio/gpio.h>
 17#include <dt-bindings/input/input.h>
 18#include <dt-bindings/interrupt-controller/irq.h>
 19
 20/ {
 21	model = "KZM-A9-GT";
 22	compatible = "renesas,kzm9g", "renesas,sh73a0";
 23
 24	aliases {
 25		serial4 = &scifa4;
 26	};
 27
 28	cpus {
 29		cpu@0 {
 30			cpu0-supply = <&vdd_dvfs>;
 31			operating-points = <
 32				/* kHz  uV */
 33				1196000 1315000
 34				 598000 1175000
 35				 398667 1065000
 36			>;
 37			voltage-tolerance = <1>; /* 1% */
 38		};
 39	};
 40
 41	chosen {
 42		bootargs = "console=tty0 console=ttySC4,115200 root=/dev/nfs ip=dhcp ignore_loglevel rw";
 43		stdout-path = &scifa4;
 44	};
 45
 46	memory {
 47		device_type = "memory";
 48		reg = <0x40000000 0x20000000>;
 49	};
 50
 51	reg_1p8v: regulator@0 {
 52		compatible = "regulator-fixed";
 53		regulator-name = "fixed-1.8V";
 54		regulator-min-microvolt = <1800000>;
 55		regulator-max-microvolt = <1800000>;
 56		regulator-always-on;
 57		regulator-boot-on;
 58	};
 59
 60	reg_3p3v: regulator@1 {
 61		compatible = "regulator-fixed";
 62		regulator-name = "fixed-3.3V";
 63		regulator-min-microvolt = <3300000>;
 64		regulator-max-microvolt = <3300000>;
 65		regulator-always-on;
 66		regulator-boot-on;
 67	};
 68
 69	vmmc_sdhi0: regulator@2 {
 70		compatible = "regulator-fixed";
 71		regulator-name = "SDHI0 Vcc";
 72		regulator-min-microvolt = <3300000>;
 73		regulator-max-microvolt = <3300000>;
 74		gpio = <&pfc 15 GPIO_ACTIVE_HIGH>;
 75		enable-active-high;
 76	};
 77
 78	vmmc_sdhi2: regulator@3 {
 79		compatible = "regulator-fixed";
 80		regulator-name = "SDHI2 Vcc";
 81		regulator-min-microvolt = <3300000>;
 82		regulator-max-microvolt = <3300000>;
 83		gpio = <&pfc 14 GPIO_ACTIVE_HIGH>;
 84		enable-active-high;
 85	};
 86
 87	leds {
 88		compatible = "gpio-leds";
 89		led1 {
 90			gpios = <&pfc 20 GPIO_ACTIVE_LOW>;
 91			label = "LED1";
 92		};
 93		led2 {
 94			gpios = <&pfc 21 GPIO_ACTIVE_LOW>;
 95			label = "LED2";
 96		};
 97		led3 {
 98			gpios = <&pfc 22 GPIO_ACTIVE_LOW>;
 99			label = "LED3";
100		};
101		led4 {
102			gpios = <&pfc 23 GPIO_ACTIVE_LOW>;
103			label = "LED4";
104		};
105	};
106
107	keyboard {
108		compatible = "gpio-keys";
109
110		back-key {
111			gpios = <&pcf8575 8 GPIO_ACTIVE_LOW>;
112			linux,code = <KEY_BACK>;
113			label = "SW3";
114		};
115
116		right-key {
117			gpios = <&pcf8575 9 GPIO_ACTIVE_LOW>;
118			linux,code = <KEY_RIGHT>;
119			label = "SW2-R";
120		};
121
122		left-key {
123			gpios = <&pcf8575 10 GPIO_ACTIVE_LOW>;
124			linux,code = <KEY_LEFT>;
125			label = "SW2-L";
126		};
127
128		enter-key {
129			gpios = <&pcf8575 11 GPIO_ACTIVE_LOW>;
130			linux,code = <KEY_ENTER>;
131			label = "SW2-P";
132		};
133
134		up-key {
135			gpios = <&pcf8575 12 GPIO_ACTIVE_LOW>;
136			linux,code = <KEY_UP>;
137			label = "SW2-U";
138		};
139
140		down-key {
141			gpios = <&pcf8575 13 GPIO_ACTIVE_LOW>;
142			linux,code = <KEY_DOWN>;
143			label = "SW2-D";
144		};
145
146		home-key {
147			gpios = <&pcf8575 14 GPIO_ACTIVE_LOW>;
148			linux,code = <KEY_HOME>;
149			label = "SW1";
150			wakeup-source;
151		};
 
 
 
 
 
 
 
152	};
153
154	sound {
155		compatible = "simple-audio-card";
156		simple-audio-card,format = "left_j";
157		simple-audio-card,cpu {
158			sound-dai = <&sh_fsi2 0>;
159		};
160		simple-audio-card,codec {
161			sound-dai = <&ak4648>;
162			bitclock-master;
163			frame-master;
164			system-clock-frequency = <11289600>;
165		};
166	};
167};
168
169&bsc {
170	ethernet@10000000 {
171		compatible = "smsc,lan9220", "smsc,lan9115";
172		reg = <0x10000000 0x100>;
173		phy-mode = "mii";
174		interrupt-parent = <&irqpin0>;
175		interrupts = <3 IRQ_TYPE_EDGE_FALLING>;
176		reg-io-width = <4>;
177		smsc,irq-push-pull;
178		smsc,save-mac-address;
179		vddvario-supply = <&reg_1p8v>;
180		vdd33a-supply = <&reg_3p3v>;
181	};
182};
183
184&cmt1 {
185	status = "okay";
186};
187
188&extal2_clk {
189	clock-frequency = <48000000>;
190};
191
192&i2c0 {
193	status = "okay";
194
195	compass@c {
196		compatible = "asahi-kasei,ak8975";
197		reg = <0x0c>;
198		interrupt-parent = <&irqpin3>;
199		interrupts = <4 IRQ_TYPE_EDGE_FALLING>;
200	};
201
202	ak4648: codec@12 {
203		compatible = "asahi-kasei,ak4648";
204		reg = <0x12>;
205		#sound-dai-cells = <0>;
206	};
207
208	accelerometer@1d {
209		compatible = "adi,adxl345";
210		reg = <0x1d>;
211		interrupt-parent = <&irqpin3>;
212		interrupts = <2 IRQ_TYPE_LEVEL_HIGH>,
213			     <3 IRQ_TYPE_LEVEL_HIGH>;
214	};
215
216	rtc@32 {
217		compatible = "ricoh,r2025sd";
218		reg = <0x32>;
219	};
220
221	as3711@40 {
222		compatible = "ams,as3711";
223		reg = <0x40>;
224
225		regulators {
226			vdd_dvfs: sd1 {
227				regulator-name = "1.315V CPU";
228				regulator-min-microvolt = <1050000>;
229				regulator-max-microvolt = <1350000>;
230				regulator-always-on;
231				regulator-boot-on;
232			};
233			sd2 {
234				regulator-name = "1.8V";
235				regulator-min-microvolt = <1800000>;
236				regulator-max-microvolt = <1800000>;
237				regulator-always-on;
238				regulator-boot-on;
239			};
240			sd4 {
241				regulator-name = "1.215V";
242				regulator-min-microvolt = <1215000>;
243				regulator-max-microvolt = <1235000>;
244				regulator-always-on;
245				regulator-boot-on;
246			};
247			ldo2 {
248				regulator-name = "2.8V CPU";
249				regulator-min-microvolt = <2800000>;
250				regulator-max-microvolt = <2800000>;
251				regulator-always-on;
252				regulator-boot-on;
253			};
254			ldo3 {
255				regulator-name = "3.0V CPU";
256				regulator-min-microvolt = <3000000>;
257				regulator-max-microvolt = <3000000>;
258				regulator-always-on;
259				regulator-boot-on;
260			};
261			ldo4 {
262				regulator-name = "2.8V";
263				regulator-min-microvolt = <2800000>;
264				regulator-max-microvolt = <2800000>;
265				regulator-always-on;
266				regulator-boot-on;
267			};
268			ldo5 {
269				regulator-name = "2.8V #2";
270				regulator-min-microvolt = <2800000>;
271				regulator-max-microvolt = <2800000>;
272				regulator-always-on;
273				regulator-boot-on;
274			};
275			ldo7 {
276				regulator-name = "1.15V CPU";
277				regulator-min-microvolt = <1150000>;
278				regulator-max-microvolt = <1150000>;
279				regulator-always-on;
280				regulator-boot-on;
281			};
282			ldo8 {
283				regulator-name = "1.15V CPU #2";
284				regulator-min-microvolt = <1150000>;
285				regulator-max-microvolt = <1150000>;
286				regulator-always-on;
287				regulator-boot-on;
288			};
289		};
290	};
291};
292
293&i2c1 {
294	status = "okay";
295
296	touchscreen@55 {
297		compatible = "sitronix,st1232";
298		reg = <0x55>;
299		interrupt-parent = <&irqpin1>;
300		interrupts = <0 IRQ_TYPE_EDGE_FALLING>;
301	};
302};
303
304&i2c3 {
305	pinctrl-0 = <&i2c3_pins>;
306	pinctrl-names = "default";
307	status = "okay";
308
309	pcf8575: gpio@20 {
310		compatible = "nxp,pcf8575";
311		reg = <0x20>;
312		interrupt-parent = <&irqpin2>;
313		interrupts = <3 IRQ_TYPE_EDGE_FALLING>;
314		gpio-controller;
315		#gpio-cells = <2>;
316		interrupt-controller;
317		#interrupt-cells = <2>;
318	};
319};
320
321&mmcif {
322	pinctrl-0 = <&mmcif_pins>;
323	pinctrl-names = "default";
324
325	bus-width = <8>;
326	vmmc-supply = <&reg_1p8v>;
327	status = "okay";
328};
329
330&pfc {
331	i2c3_pins: i2c3 {
332		renesas,groups = "i2c3_1";
333		renesas,function = "i2c3";
334	};
335
336	mmcif_pins: mmc {
337		mux {
338			renesas,groups = "mmc0_data8_0", "mmc0_ctrl_0";
339			renesas,function = "mmc0";
340		};
341		cfg {
342			renesas,groups = "mmc0_data8_0";
343			renesas,pins = "PORT279";
344			bias-pull-up;
345		};
346	};
347
348	scifa4_pins: serial4 {
349		renesas,groups = "scifa4_data", "scifa4_ctrl";
350		renesas,function = "scifa4";
351	};
352
353	sdhi0_pins: sd0 {
354		renesas,groups = "sdhi0_data4", "sdhi0_ctrl", "sdhi0_cd", "sdhi0_wp";
355		renesas,function = "sdhi0";
356	};
357
358	sdhi2_pins: sd2 {
359		renesas,groups = "sdhi2_data4", "sdhi2_ctrl";
360		renesas,function = "sdhi2";
361	};
362
363	fsia_pins: sounda {
364		renesas,groups = "fsia_mclk_in", "fsia_sclk_in",
365				 "fsia_data_in", "fsia_data_out";
366		renesas,function = "fsia";
367	};
368};
369
370&scifa4 {
371	pinctrl-0 = <&scifa4_pins>;
372	pinctrl-names = "default";
373
 
374	status = "okay";
375};
376
377&sdhi0 {
378	pinctrl-0 = <&sdhi0_pins>;
379	pinctrl-names = "default";
380
381	vmmc-supply = <&vmmc_sdhi0>;
382	bus-width = <4>;
383	status = "okay";
384};
385
386&sdhi2 {
387	pinctrl-0 = <&sdhi2_pins>;
388	pinctrl-names = "default";
389
390	vmmc-supply = <&vmmc_sdhi2>;
391	bus-width = <4>;
392	broken-cd;
393	status = "okay";
394};
395
396&sh_fsi2 {
397	pinctrl-0 = <&fsia_pins>;
398	pinctrl-names = "default";
399
400	status = "okay";
401};