0001 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
0002 // Copyright (c) 2021 T-Chip Intelligent Technology Co., Ltd
0003
0004 /dts-v1/;
0005
0006 #include <dt-bindings/input/input.h>
0007
0008 #include "rk3328-roc-cc.dts"
0009
0010 / {
0011 model = "Firefly ROC-RK3328-PC";
0012 compatible = "firefly,roc-rk3328-pc", "rockchip,rk3328";
0013
0014 adc-keys {
0015 compatible = "adc-keys";
0016 io-channels = <&saradc 0>;
0017 io-channel-names = "buttons";
0018 keyup-threshold-microvolt = <1750000>;
0019
0020 /* This button is unpopulated out of the factory. */
0021 button-recovery {
0022 label = "Recovery";
0023 linux,code = <KEY_VENDOR>;
0024 press-threshold-microvolt = <10000>;
0025 };
0026 };
0027
0028 ir-receiver {
0029 compatible = "gpio-ir-receiver";
0030 gpios = <&gpio2 RK_PA2 GPIO_ACTIVE_LOW>;
0031 linux,rc-map-name = "rc-khadas";
0032 pinctrl-names = "default";
0033 pinctrl-0 = <&ir_int>;
0034 };
0035
0036 sdio_pwrseq: sdio-pwrseq {
0037 compatible = "mmc-pwrseq-simple";
0038 pinctrl-names = "default";
0039 pinctrl-0 = <&wifi_en>, <&wifi_host_wake>;
0040 reset-gpios = <&gpio3 RK_PB0 GPIO_ACTIVE_LOW>;
0041 };
0042 };
0043
0044 &codec {
0045 mute-gpios = <&grf_gpio 0 GPIO_ACTIVE_LOW>;
0046 };
0047
0048 &gpu {
0049 mali-supply = <&vdd_logic>;
0050 };
0051
0052 &pinctrl {
0053 ir {
0054 ir_int: ir-int {
0055 rockchip,pins = <2 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
0056 };
0057 };
0058
0059 sdmmcio {
0060 sdio_per_pin: sdio-per-pin {
0061 rockchip,pins = <0 RK_PD3 RK_FUNC_GPIO &pcfg_pull_down>;
0062 };
0063 };
0064
0065 wifi {
0066 wifi_en: wifi-en {
0067 rockchip,pins = <3 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>;
0068 };
0069
0070 wifi_host_wake: wifi-host-wake {
0071 rockchip,pins = <3 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none_4ma>;
0072 };
0073
0074 bt_rst: bt-rst {
0075 rockchip,pins = <1 RK_PD0 RK_FUNC_GPIO &pcfg_pull_none>;
0076 };
0077
0078 bt_en: bt-en {
0079 rockchip,pins = <1 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>;
0080 };
0081 };
0082 };
0083
0084 &pmic_int_l {
0085 rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>;
0086 };
0087
0088 &rk805 {
0089 interrupt-parent = <&gpio0>;
0090 interrupts = <RK_PA2 IRQ_TYPE_LEVEL_LOW>;
0091 };
0092
0093 &saradc {
0094 vref-supply = <&vcc_18>;
0095 status = "okay";
0096 };
0097
0098 &usb20_host_drv {
0099 rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_up>;
0100 };
0101
0102 &vcc_host1_5v {
0103 gpio = <&gpio0 RK_PA0 GPIO_ACTIVE_HIGH>;
0104 };
0105
0106 &vcc_sdio {
0107 gpios = <&gpio0 RK_PD3 GPIO_ACTIVE_HIGH>;
0108 pinctrl-names = "default";
0109 pinctrl-0 = <&sdio_per_pin>;
0110 };