xref: /freebsd/sys/contrib/device-tree/src/arm64/amlogic/meson-gxbb-wetek-play2.dts (revision 7ef62cebc2f965b0f640263e179276928885e33d)
1// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright (c) 2016 BayLibre, Inc.
4 * Author: Neil Armstrong <narmstrong@baylibre.com>
5 */
6
7/dts-v1/;
8
9#include "meson-gxbb-wetek.dtsi"
10#include <dt-bindings/input/input.h>
11#include <dt-bindings/sound/meson-aiu.h>
12
13/ {
14	compatible = "wetek,play2", "amlogic,meson-gxbb";
15	model = "WeTek Play 2";
16
17	spdif_dit: audio-codec-0 {
18		#sound-dai-cells = <0>;
19		compatible = "linux,spdif-dit";
20		status = "okay";
21		sound-name-prefix = "DIT";
22	};
23
24	leds {
25		led-wifi {
26			label = "wetek-play:wifi-status";
27			gpios = <&gpio GPIODV_26 GPIO_ACTIVE_HIGH>;
28			default-state = "off";
29		};
30
31		led-ethernet {
32			label = "wetek-play:ethernet-status";
33			gpios = <&gpio GPIODV_27 GPIO_ACTIVE_HIGH>;
34			default-state = "off";
35		};
36	};
37
38	gpio-keys-polled {
39		compatible = "gpio-keys-polled";
40		poll-interval = <100>;
41
42		button {
43			label = "reset";
44			linux,code = <KEY_RESTART>;
45			gpios = <&gpio_ao GPIOAO_3 GPIO_ACTIVE_LOW>;
46		};
47	};
48
49	sound {
50		compatible = "amlogic,gx-sound-card";
51		model = "WETEK-PLAY2";
52		assigned-clocks = <&clkc CLKID_MPLL0>,
53				  <&clkc CLKID_MPLL1>,
54				  <&clkc CLKID_MPLL2>;
55		assigned-clock-parents = <0>, <0>, <0>;
56		assigned-clock-rates = <294912000>,
57				       <270950400>,
58				       <393216000>;
59		status = "okay";
60
61		dai-link-0 {
62			sound-dai = <&aiu AIU_CPU CPU_I2S_FIFO>;
63		};
64
65		dai-link-1 {
66			sound-dai = <&aiu AIU_CPU CPU_SPDIF_FIFO>;
67		};
68
69		dai-link-2 {
70			sound-dai = <&aiu AIU_CPU CPU_I2S_ENCODER>;
71			dai-format = "i2s";
72			mclk-fs = <256>;
73
74			codec-0 {
75				sound-dai = <&aiu AIU_HDMI CTRL_I2S>;
76			};
77		};
78
79		dai-link-3 {
80			sound-dai = <&aiu AIU_CPU CPU_SPDIF_ENCODER>;
81
82			codec-0 {
83				sound-dai = <&spdif_dit>;
84			};
85		};
86
87		dai-link-4 {
88			sound-dai = <&aiu AIU_HDMI CTRL_OUT>;
89
90			codec-0 {
91				sound-dai = <&hdmi_tx>;
92			};
93		};
94	};
95};
96
97&aiu {
98	status = "okay";
99	pinctrl-0 = <&spdif_out_y_pins>;
100	pinctrl-names = "default";
101};
102
103&i2c_A {
104	status = "okay";
105	pinctrl-0 = <&i2c_a_pins>;
106	pinctrl-names = "default";
107};
108
109&usb1_phy {
110	status = "okay";
111};
112
113&usb1 {
114	status = "okay";
115};
116
117&ir {
118	linux,rc-map-name = "rc-wetek-play2";
119};
120