Skip to content

Commit 5e4bbe5

Browse files
vedantd-nvthierryreding
authored andcommitted
arm64: tegra: Restructure Orin NX/Nano device tree
The Orin NX and Orin Nano boards share a common carrier board and the module boards for both platforms are very similar. Therefore, restructure the Orin NX/Nano device-tree source files to adhere to a simple hierarchical format. This will help make clear where changes should go, and eliminates redundancy within the files. Previously the carrier board file was independent. However, given that it is so tightly coupled with the module design, it will be more practical to combine files together for a simpler layout. Following changes are made to restructure the device tree source files: 1) Change include hierarchy. Top-level dts includes board dtsi. Board dtsi includes module dtsi. Module dtsi includes SoC dtsi. 2) Data from the top level dts file that is common to both Orin NX and Orin Nano is in tegra234-p3768-0000+p3767.dtsi. 3) Only data that is unique to NX/Nano is present in the top-level dts. Signed-off-by: Vedant Deshpande <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
1 parent 1613e60 commit 5e4bbe5

File tree

3 files changed

+29
-107
lines changed

3 files changed

+29
-107
lines changed
Lines changed: 1 addition & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
// SPDX-License-Identifier: GPL-2.0
22
/dts-v1/;
33

4-
#include <dt-bindings/input/linux-event-codes.h>
5-
#include <dt-bindings/input/gpio-keys.h>
6-
7-
#include "tegra234-p3767.dtsi"
8-
#include "tegra234-p3768-0000.dtsi"
4+
#include "tegra234-p3768-0000+p3767.dtsi"
95

106
/ {
117
compatible = "nvidia,p3768-0000+p3767-0000", "nvidia,p3767-0000", "nvidia,tegra234";
@@ -29,83 +25,12 @@
2925
status = "okay";
3026
};
3127

32-
pwm@32a0000 {
33-
assigned-clocks = <&bpmp TEGRA234_CLK_PWM3>;
34-
assigned-clock-parents = <&bpmp TEGRA234_CLK_PLLP_OUT0>;
35-
status = "okay";
36-
};
37-
3828
hda@3510000 {
3929
nvidia,model = "NVIDIA Jetson Orin NX HDA";
4030
};
41-
42-
padctl@3520000 {
43-
status = "okay";
44-
};
45-
};
46-
47-
gpio-keys {
48-
compatible = "gpio-keys";
49-
50-
key-force-recovery {
51-
label = "Force Recovery";
52-
gpios = <&gpio TEGRA234_MAIN_GPIO(G, 0) GPIO_ACTIVE_LOW>;
53-
linux,input-type = <EV_KEY>;
54-
linux,code = <BTN_1>;
55-
};
56-
57-
key-power {
58-
label = "Power";
59-
gpios = <&gpio_aon TEGRA234_AON_GPIO(EE, 4) GPIO_ACTIVE_LOW>;
60-
linux,input-type = <EV_KEY>;
61-
linux,code = <KEY_POWER>;
62-
wakeup-event-action = <EV_ACT_ASSERTED>;
63-
wakeup-source;
64-
};
65-
66-
key-suspend {
67-
label = "Suspend";
68-
gpios = <&gpio TEGRA234_MAIN_GPIO(G, 2) GPIO_ACTIVE_LOW>;
69-
linux,input-type = <EV_KEY>;
70-
linux,code = <KEY_SLEEP>;
71-
};
72-
};
73-
74-
pwm-fan {
75-
cooling-levels = <0 88 187 255>;
76-
};
77-
78-
vdd_3v3_pcie: regulator-vdd-3v3-pcie {
79-
compatible = "regulator-fixed";
80-
regulator-name = "VDD_3V3_PCIE";
81-
regulator-min-microvolt = <3300000>;
82-
regulator-max-microvolt = <3300000>;
83-
gpio = <&gpio_aon TEGRA234_AON_GPIO(AA, 5) GPIO_ACTIVE_HIGH>;
84-
enable-active-high;
8531
};
8632

8733
sound {
8834
label = "NVIDIA Jetson Orin NX APE";
8935
};
90-
91-
thermal-zones {
92-
tj-thermal {
93-
cooling-maps {
94-
map-active-0 {
95-
cooling-device = <&fan 0 1>;
96-
trip = <&tj_trip_active0>;
97-
};
98-
99-
map-active-1 {
100-
cooling-device = <&fan 1 2>;
101-
trip = <&tj_trip_active1>;
102-
};
103-
104-
map-active-2 {
105-
cooling-device = <&fan 2 3>;
106-
trip = <&tj_trip_active2>;
107-
};
108-
};
109-
};
110-
};
11136
};
Lines changed: 1 addition & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
// SPDX-License-Identifier: GPL-2.0
22
/dts-v1/;
33

4-
#include <dt-bindings/input/linux-event-codes.h>
5-
#include <dt-bindings/input/gpio-keys.h>
6-
7-
#include "tegra234-p3767.dtsi"
8-
#include "tegra234-p3768-0000.dtsi"
4+
#include "tegra234-p3768-0000+p3767.dtsi"
95

106
/ {
117
compatible = "nvidia,p3768-0000+p3767-0005", "nvidia,p3767-0005", "nvidia,tegra234";
@@ -17,32 +13,7 @@
1713
};
1814
};
1915

20-
pwm-fan {
21-
cooling-levels = <0 88 187 255>;
22-
};
23-
2416
sound {
2517
label = "NVIDIA Jetson Orin Nano APE";
2618
};
27-
28-
thermal-zones {
29-
tj-thermal {
30-
cooling-maps {
31-
map-active-0 {
32-
cooling-device = <&fan 0 1>;
33-
trip = <&tj_trip_active0>;
34-
};
35-
36-
map-active-1 {
37-
cooling-device = <&fan 1 2>;
38-
trip = <&tj_trip_active1>;
39-
};
40-
41-
map-active-2 {
42-
cooling-device = <&fan 2 3>;
43-
trip = <&tj_trip_active2>;
44-
};
45-
};
46-
};
47-
};
4819
};

arch/arm64/boot/dts/nvidia/tegra234-p3768-0000.dtsi renamed to arch/arm64/boot/dts/nvidia/tegra234-p3768-0000+p3767.dtsi

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
// SPDX-License-Identifier: GPL-2.0
22

3+
#include <dt-bindings/input/linux-event-codes.h>
4+
#include <dt-bindings/input/gpio-keys.h>
5+
6+
#include "tegra234-p3767.dtsi"
7+
38
/ {
4-
compatible = "nvidia,p3768-0000";
59

610
aliases {
711
serial0 = &tcu;
@@ -210,6 +214,7 @@
210214
compatible = "pwm-fan";
211215
pwms = <&pwm3 0 45334>;
212216
#cooling-cells = <2>;
217+
cooling-levels = <0 88 187 255>;
213218
};
214219

215220
vdd_1v8_sys: regulator-vdd-1v8-sys {
@@ -241,4 +246,25 @@
241246
serial {
242247
status = "okay";
243248
};
249+
250+
thermal-zones {
251+
tj-thermal {
252+
cooling-maps {
253+
map-active-0 {
254+
cooling-device = <&fan 0 1>;
255+
trip = <&tj_trip_active0>;
256+
};
257+
258+
map-active-1 {
259+
cooling-device = <&fan 1 2>;
260+
trip = <&tj_trip_active1>;
261+
};
262+
263+
map-active-2 {
264+
cooling-device = <&fan 2 3>;
265+
trip = <&tj_trip_active2>;
266+
};
267+
};
268+
};
269+
};
244270
};

0 commit comments

Comments
 (0)