diff --git a/overlay/Makefile b/overlay/Makefile index a08e3f4..335a42b 100644 --- a/overlay/Makefile +++ b/overlay/Makefile @@ -14,9 +14,11 @@ dtbo-y += tegra234-audio-overlay.dtbo dtbo-y += tegra234-carveouts.dtbo dtbo-y += tegra234-jetson.dtbo dtbo-y += tegra234-p3737-0000+p3701-0000.dtbo +dtbo-y += tegra234-p3737-0000+p3701-0000-dynamic.dtbo dtbo-y += tegra234-p3740-0002+p3701-0008.dtbo dtbo-y += tegra234-p3740-0002+p3701-0008-safety.dtbo dtbo-y += tegra234-p3768-0000+p3767-0000.dtbo +dtbo-y += tegra234-p3768-0000+p3767-0000-dynamic.dtbo dtbo-y += tegra234-p3737-0000+p3701-0000-audio-adafruit-uda1334a.dtbo dtbo-y += tegra234-p3737-0000+p3701-0000-audio-adafruit-sph0645lm4h.dtbo dtbo-y += tegra234-p3737-0000+p3701-0000-audio-fe-pi.dtbo diff --git a/overlay/tegra234-p3701-0000.dtsi b/overlay/tegra234-p3701-0000.dtsi index a27cbb6..244d6f1 100644 --- a/overlay/tegra234-p3701-0000.dtsi +++ b/overlay/tegra234-p3701-0000.dtsi @@ -151,18 +151,4 @@ }; }; }; - - fragment-t234-p3701-0000@1 { - target-path = "/"; - board_config { - ids = "3701-0005-*","3701-0008-*"; - }; - __overlay__ { - reserved-memory { - linux,cma { /* Needed for nvgpu comptags */ - size = <0x0 0x20000000>; /* 512MB */ - }; - }; - }; - }; }; diff --git a/overlay/tegra234-p3737-0000+p3701-0000-dynamic.dts b/overlay/tegra234-p3737-0000+p3701-0000-dynamic.dts new file mode 100644 index 0000000..fddbac3 --- /dev/null +++ b/overlay/tegra234-p3737-0000+p3701-0000-dynamic.dts @@ -0,0 +1,84 @@ +// SPDX-License-Identifier: GPL-2.0-only +// Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. + +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment-t234-p3737-0000-p3701-0000@0 { + target-path = "/"; + board_config { + ids = "3701-0005-*","3701-0008-*"; + }; + __overlay__ { + reserved-memory { + linux,cma { /* Needed for nvgpu comptags */ + size = <0x0 0x20000000>; /* 512MB */ + }; + }; + }; + }; + + fragment-t234-p3737-0000-p3701-0000@1 { + target-path = "/"; + board_config { + ids = ">=3737-0000-TS4", ">=3737-0000-RC1", ">=3737-0000-300"; + }; + __overlay__ { + bus@0 { + i2c@31e0000 { + rt5640: audio-codec@1c { + #sound-dai-cells = <1>; + status = "okay"; + }; + }; + }; + + sound { + nvidia-audio-card,widgets = + "Headphone", "CVB-RT Headphone Jack", + "Microphone", "CVB-RT Mic Jack", + "Speaker", "CVB-RT Int Spk", + "Microphone", "CVB-RT Int Mic"; + + nvidia-audio-card,routing = + "CVB-RT Headphone Jack", "CVB-RT HPOL", + "CVB-RT Headphone Jack", "CVB-RT HPOR", + "CVB-RT IN1P", "CVB-RT Mic Jack", + "CVB-RT IN2P", "CVB-RT Mic Jack", + "CVB-RT Int Spk", "CVB-RT SPOLP", + "CVB-RT Int Spk", "CVB-RT SPORP", + "CVB-RT DMIC1", "CVB-RT Int Mic", + "CVB-RT DMIC2", "CVB-RT Int Mic"; + + nvidia-audio-card,dai-link@76 { + link-name = "rt5640-playback"; + codec { + sound-dai = <&rt5640 0>; + prefix = "CVB-RT"; + }; + }; + }; + }; + }; + + fragment-t234-p3737-0000-p3701-0000@2 { + target-path = "/"; + board_config { + ids = "3737-0000-TS1","3737-0000-TS2","3737-0000-TS3","3737-0000-EB1","3737-0000-EB2","3737-0000-EB3","3737-0000-000","3737-0000-100","3737-0000-200"; + }; + __overlay__ { + bus@0{ + i2c@c240000 { + typec@8 { + interrupt-parent = <&gpio_aon>; + interrupts = ; + }; + }; + }; + }; + }; +}; diff --git a/overlay/tegra234-p3737-0000.dtsi b/overlay/tegra234-p3737-0000.dtsi index 852194d..201e710 100644 --- a/overlay/tegra234-p3737-0000.dtsi +++ b/overlay/tegra234-p3737-0000.dtsi @@ -127,64 +127,4 @@ }; }; }; - - fragment-t234-p3737-0000@1 { - target-path = "/"; - board_config { - ids = ">=3737-0000-TS4", ">=3737-0000-RC1", ">=3737-0000-300"; - }; - __overlay__ { - bus@0 { - i2c@31e0000 { - rt5640: audio-codec@1c { - #sound-dai-cells = <1>; - status = "okay"; - }; - }; - }; - - sound { - nvidia-audio-card,widgets = - "Headphone", "CVB-RT Headphone Jack", - "Microphone", "CVB-RT Mic Jack", - "Speaker", "CVB-RT Int Spk", - "Microphone", "CVB-RT Int Mic"; - - nvidia-audio-card,routing = - "CVB-RT Headphone Jack", "CVB-RT HPOL", - "CVB-RT Headphone Jack", "CVB-RT HPOR", - "CVB-RT IN1P", "CVB-RT Mic Jack", - "CVB-RT IN2P", "CVB-RT Mic Jack", - "CVB-RT Int Spk", "CVB-RT SPOLP", - "CVB-RT Int Spk", "CVB-RT SPORP", - "CVB-RT DMIC1", "CVB-RT Int Mic", - "CVB-RT DMIC2", "CVB-RT Int Mic"; - - nvidia-audio-card,dai-link@76 { - link-name = "rt5640-playback"; - codec { - sound-dai = <&rt5640 0>; - prefix = "CVB-RT"; - }; - }; - }; - }; - }; - - fragment-t234-p3737-0000@3 { - target-path = "/"; - board_config { - ids = "3737-0000-TS1","3737-0000-TS2","3737-0000-TS3","3737-0000-EB1","3737-0000-EB2","3737-0000-EB3","3737-0000-000","3737-0000-100","3737-0000-200"; - }; - __overlay__ { - bus@0{ - i2c@c240000 { - typec@8 { - interrupt-parent = <&gpio_aon>; - interrupts = ; - }; - }; - }; - }; - }; }; diff --git a/overlay/tegra234-p3768-0000+p3767-0000-dynamic.dts b/overlay/tegra234-p3768-0000+p3767-0000-dynamic.dts new file mode 100644 index 0000000..a29c06c --- /dev/null +++ b/overlay/tegra234-p3768-0000+p3767-0000-dynamic.dts @@ -0,0 +1,13 @@ +// SPDX-License-Identifier: GPL-2.0-only +// Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. + +/dts-v1/; +/plugin/; + +/* + * Include this file last in the device tree. It manages run-time + * pruning of peripherals that are not available across the various + * SKUs of p3767. For example PVA can be enabled in the device tree + * and it will automatically be disabled for SKUs without PVA support. + */ +#include "tegra234-p3767-sku-handling.dtsi" diff --git a/overlay/tegra234-p3768-0000+p3767-0000.dts b/overlay/tegra234-p3768-0000+p3767-0000.dts index dd59d28..0cb411b 100644 --- a/overlay/tegra234-p3768-0000+p3767-0000.dts +++ b/overlay/tegra234-p3768-0000+p3767-0000.dts @@ -393,11 +393,3 @@ }; }; }; - -/* - * Include this file last in the device tree. It manages run-time - * pruning of peripherals that are not available across the various - * SKUs of p3767. For example PVA can be enabled in the device tree - * and it will automatically be disabled for SKUs without PVA support. - */ -#include "tegra234-p3767-sku-handling.dtsi"