Manivannan Sadhasivam | 88a0f50 | 2018-09-28 00:33:01 +0530 | [diff] [blame] | 1 | // SPDX-License-Identifier: (GPL-2.0+ OR MIT) |
| 2 | /* |
| 3 | * Copyright (c) 2018 Collabora Ltd. |
| 4 | * Copyright (c) 2018 Fuzhou Rockchip Electronics Co., Ltd. |
| 5 | * |
| 6 | * Schematics available at https://dl.vamrs.com/products/ficus/docs/hw |
| 7 | */ |
| 8 | |
| 9 | /dts-v1/; |
| 10 | #include "rk3399-rock960.dtsi" |
Manivannan Sadhasivam | 88a0f50 | 2018-09-28 00:33:01 +0530 | [diff] [blame] | 11 | |
| 12 | / { |
| 13 | model = "96boards RK3399 Ficus"; |
| 14 | compatible = "vamrs,ficus", "rockchip,rk3399"; |
| 15 | |
| 16 | chosen { |
| 17 | stdout-path = "serial2:1500000n8"; |
| 18 | }; |
| 19 | |
| 20 | clkin_gmac: external-gmac-clock { |
| 21 | compatible = "fixed-clock"; |
| 22 | clock-frequency = <125000000>; |
| 23 | clock-output-names = "clkin_gmac"; |
| 24 | #clock-cells = <0>; |
| 25 | }; |
Peter Robinson | c91fb87 | 2019-07-01 17:05:49 +0100 | [diff] [blame] | 26 | |
| 27 | leds { |
| 28 | compatible = "gpio-leds"; |
| 29 | pinctrl-names = "default"; |
| 30 | pinctrl-0 = <&user_led1>, <&user_led2>, <&user_led3>, |
| 31 | <&user_led4>, <&wlan_led>, <&bt_led>; |
| 32 | |
| 33 | user_led1 { |
| 34 | label = "red:user1"; |
| 35 | gpios = <&gpio4 25 0>; |
| 36 | linux,default-trigger = "heartbeat"; |
| 37 | }; |
| 38 | |
| 39 | user_led2 { |
| 40 | label = "red:user2"; |
| 41 | gpios = <&gpio4 26 0>; |
| 42 | linux,default-trigger = "mmc0"; |
| 43 | }; |
| 44 | |
| 45 | user_led3 { |
| 46 | label = "red:user3"; |
| 47 | gpios = <&gpio4 30 0>; |
| 48 | linux,default-trigger = "mmc1"; |
| 49 | }; |
| 50 | |
| 51 | user_led4 { |
| 52 | label = "red:user4"; |
| 53 | gpios = <&gpio1 0 0>; |
| 54 | panic-indicator; |
| 55 | linux,default-trigger = "none"; |
| 56 | }; |
| 57 | |
| 58 | wlan_active_led { |
| 59 | label = "red:wlan"; |
| 60 | gpios = <&gpio1 1 0>; |
| 61 | linux,default-trigger = "phy0tx"; |
| 62 | default-state = "off"; |
| 63 | }; |
| 64 | |
| 65 | bt_active_led { |
| 66 | label = "red:bt"; |
| 67 | gpios = <&gpio1 4 0>; |
| 68 | linux,default-trigger = "hci0-power"; |
| 69 | default-state = "off"; |
| 70 | }; |
| 71 | }; |
Manivannan Sadhasivam | 88a0f50 | 2018-09-28 00:33:01 +0530 | [diff] [blame] | 72 | }; |
| 73 | |
| 74 | &gmac { |
| 75 | assigned-clocks = <&cru SCLK_RMII_SRC>; |
| 76 | assigned-clock-parents = <&clkin_gmac>; |
| 77 | clock_in_out = "input"; |
| 78 | phy-supply = <&vcc3v3_sys>; |
| 79 | phy-mode = "rgmii"; |
| 80 | pinctrl-names = "default"; |
| 81 | pinctrl-0 = <&rgmii_pins>; |
| 82 | snps,reset-gpio = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>; |
| 83 | snps,reset-active-low; |
| 84 | snps,reset-delays-us = <0 10000 50000>; |
| 85 | tx_delay = <0x28>; |
| 86 | rx_delay = <0x11>; |
| 87 | status = "okay"; |
| 88 | }; |
| 89 | |
| 90 | &pcie0 { |
| 91 | ep-gpios = <&gpio4 RK_PD4 GPIO_ACTIVE_HIGH>; |
| 92 | }; |
| 93 | |
| 94 | &pinctrl { |
| 95 | gmac { |
| 96 | rgmii_sleep_pins: rgmii-sleep-pins { |
| 97 | rockchip,pins = |
Peter Robinson | c91fb87 | 2019-07-01 17:05:49 +0100 | [diff] [blame] | 98 | <3 RK_PB7 RK_FUNC_GPIO &pcfg_output_low>; |
Manivannan Sadhasivam | 88a0f50 | 2018-09-28 00:33:01 +0530 | [diff] [blame] | 99 | }; |
| 100 | }; |
| 101 | |
| 102 | pcie { |
| 103 | pcie_drv: pcie-drv { |
| 104 | rockchip,pins = |
Peter Robinson | c91fb87 | 2019-07-01 17:05:49 +0100 | [diff] [blame] | 105 | <1 RK_PD0 RK_FUNC_GPIO &pcfg_pull_none>; |
Manivannan Sadhasivam | 88a0f50 | 2018-09-28 00:33:01 +0530 | [diff] [blame] | 106 | }; |
| 107 | }; |
| 108 | |
| 109 | usb2 { |
| 110 | host_vbus_drv: host-vbus-drv { |
| 111 | rockchip,pins = |
Peter Robinson | c91fb87 | 2019-07-01 17:05:49 +0100 | [diff] [blame] | 112 | <4 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>; |
Manivannan Sadhasivam | 88a0f50 | 2018-09-28 00:33:01 +0530 | [diff] [blame] | 113 | }; |
| 114 | }; |
Peter Robinson | c91fb87 | 2019-07-01 17:05:49 +0100 | [diff] [blame] | 115 | |
| 116 | leds { |
| 117 | user_led1: user_led1 { |
| 118 | rockchip,pins = |
| 119 | <4 RK_PD1 RK_FUNC_GPIO &pcfg_pull_none>; |
| 120 | }; |
| 121 | |
| 122 | user_led2: user_led2 { |
| 123 | rockchip,pins = |
| 124 | <4 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>; |
| 125 | }; |
| 126 | |
| 127 | user_led3: user_led3 { |
| 128 | rockchip,pins = |
| 129 | <4 RK_PD6 RK_FUNC_GPIO &pcfg_pull_none>; |
| 130 | }; |
| 131 | |
| 132 | user_led4: user_led4 { |
| 133 | rockchip,pins = |
| 134 | <1 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>; |
| 135 | }; |
| 136 | |
| 137 | wlan_led: wlan_led { |
| 138 | rockchip,pins = |
| 139 | <1 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>; |
| 140 | }; |
| 141 | |
| 142 | bt_led: bt_led { |
| 143 | rockchip,pins = |
| 144 | <1 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>; |
| 145 | }; |
| 146 | }; |
| 147 | }; |
| 148 | |
Jagan Teki | 5cc2118 | 2020-04-28 15:30:17 +0530 | [diff] [blame] | 149 | &spi1 { |
| 150 | /* On both Low speed and High speed expansion */ |
| 151 | cs-gpios = <0>, <&gpio4 RK_PA6 0>, <&gpio4 RK_PA7 0>; |
| 152 | status = "okay"; |
| 153 | }; |
| 154 | |
Peter Robinson | c91fb87 | 2019-07-01 17:05:49 +0100 | [diff] [blame] | 155 | &usbdrd_dwc3_0 { |
| 156 | dr_mode = "host"; |
| 157 | }; |
| 158 | |
| 159 | &usbdrd_dwc3_1 { |
| 160 | dr_mode = "host"; |
Manivannan Sadhasivam | 88a0f50 | 2018-09-28 00:33:01 +0530 | [diff] [blame] | 161 | }; |
| 162 | |
| 163 | &vcc3v3_pcie { |
| 164 | gpio = <&gpio1 24 GPIO_ACTIVE_HIGH>; |
| 165 | }; |
| 166 | |
| 167 | &vcc5v0_host { |
| 168 | gpio = <&gpio4 27 GPIO_ACTIVE_HIGH>; |
| 169 | }; |