Tegra CEC Updates
Subsystems (4)
v2 cover Tegra CEC Updates
This series updates Tegra hdmi cec support to be usable out of the box on Tegra210 through Tegra194.
---
Changes in v2:
- Dropped patch 2, per request
- Added change to declare fallback compatibles instead, as per request
- Update patch 1 to allow fallback compatibles
- Link to v1: https://lore.kernel.org/r/[email protected]
---
Aaron Kling (4):
media: dt-bindings: Document Tegra186 and Tegra194 cec
arm64: tegra: Add fallback cec compatibles
arm64: tegra: Add CEC controller on Tegra210
arm64: tegra: Wire up cec to devkits
.../bindings/media/cec/nvidia,tegra114-cec.yaml | 15 +++++++++++---- arch/arm64/boot/dts/nvidia/tegra186-p2771-0000.dts | 6 ++++++ .../boot/dts/nvidia/tegra186-p3509-0000+p3636-0001.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra186.dtsi | 2 +- arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra194-p3509-0000.dtsi | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra194.dtsi | 2 +- arch/arm64/boot/dts/nvidia/tegra210-p2371-2180.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra210-p3450-0000.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra210.dtsi | 9 +++++++++ 10 files changed, 58 insertions(+), 6 deletions(-)
---
base-commit: 0af2f6be1b4281385b618cb86ad946eded089ac8
change-id: 20250407-tegra-cec-7e3a7bef456f
Best regards,
Signature · 1 line
Aaron Kling <[email protected]>
PATCH v2 1/4 media: dt-bindings: Document Tegra186 and Tegra194 cec
These are already used in device trees, so describe them here. As the driver only declares up through Tegra210, these must use a fallback compatible of tegra210-cec.
--- .../bindings/media/cec/nvidia,tegra114-cec.yaml | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-)
Documentation/devicetree/bindings/media/cec/nvidia,tegra114-cec.yaml +11 -4
@@ -14,10 +14,17 @@ allOf: properties: compatible: - enum: - - nvidia,tegra114-cec - - nvidia,tegra124-cec - - nvidia,tegra210-cec + oneOf: + - items: + - enum: + - nvidia,tegra114-cec + - nvidia,tegra124-cec + - nvidia,tegra210-cec + - items: + - enum: + - nvidia,tegra186-cec + - nvidia,tegra194-cec + - const: nvidia,tegra210-cec clocks: maxItems: 1
Signature · 1 line
2.48.1
PATCH v2 2/4 arm64: tegra: Add fallback cec compatibles
In reply to Aaron KlingThe tegra_cec driver only declares support up to Tegra210 and will not declare support for Tegra186 or Tegra194. Thus list a fallback compatible for these archs to tegra210-cec as they work as-is with the existing driver.
--- arch/arm64/boot/dts/nvidia/tegra186.dtsi | 2 +- arch/arm64/boot/dts/nvidia/tegra194.dtsi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/nvidia/tegra186.dtsi +1 -1
@@ -1183,7 +1183,7 @@ gic: interrupt-controller@3881000 { }; cec@3960000 { - compatible = "nvidia,tegra186-cec"; + compatible = "nvidia,tegra186-cec", "nvidia,tegra210-cec"; reg = <0x0 0x03960000 0x0 0x10000>; interrupts = <GIC_SPI 162 IRQ_TYPE_LEVEL_HIGH>; clocks = <&bpmp TEGRA186_CLK_CEC>;
arch/arm64/boot/dts/nvidia/tegra194.dtsi +1 -1
@@ -1339,7 +1339,7 @@ gic: interrupt-controller@3881000 { }; cec@3960000 { - compatible = "nvidia,tegra194-cec"; + compatible = "nvidia,tegra194-cec", "nvidia,tegra210-cec"; reg = <0x0 0x03960000 0x0 0x10000>; interrupts = <GIC_SPI 162 IRQ_TYPE_LEVEL_HIGH>; clocks = <&bpmp TEGRA194_CLK_CEC>;
Signature · 1 line
2.48.1
PATCH v2 3/4 arm64: tegra: Add CEC controller on Tegra210
In reply to Aaron KlingThe CEC controller found on Tegra210 can be used to control consumer devices using the HDMI CEC pin.
--- arch/arm64/boot/dts/nvidia/tegra210.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+)
arch/arm64/boot/dts/nvidia/tegra210.dtsi +9 -0
@@ -959,6 +959,15 @@ fuse@7000f800 { reset-names = "fuse"; }; + cec@70015000 { + compatible = "nvidia,tegra210-cec"; + reg = <0x0 0x070015000 0x0 0x1000>; + interrupts = <GIC_SPI 3 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&tegra_car TEGRA210_CLK_CEC>; + clock-names = "cec"; + status = "disabled"; + }; + mc: memory-controller@70019000 { compatible = "nvidia,tegra210-mc"; reg = <0x0 0x70019000 0x0 0x1000>;
Signature · 1 line
2.48.1
PATCH v2 4/4 arm64: tegra: Wire up cec to devkits
In reply to Aaron KlingThis enables hdmi cec and routes it to the hdmi port on all supported Tegra210, Tegra186, and Tegra194 devkits.
--- arch/arm64/boot/dts/nvidia/tegra186-p2771-0000.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra186-p3509-0000+p3636-0001.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra194-p3509-0000.dtsi | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra210-p2371-2180.dts | 6 ++++++ arch/arm64/boot/dts/nvidia/tegra210-p3450-0000.dts | 6 ++++++ 6 files changed, 36 insertions(+)
arch/arm64/boot/dts/nvidia/tegra186-p2771-0000.dts +6 -0
@@ -2394,6 +2394,12 @@ usb@3550000 { phy-names = "usb2-0"; }; + cec@3960000 { + status = "okay"; + + hdmi-phandle = <&sor1>; + }; + i2c@c250000 { /* carrier board ID EEPROM */ eeprom@57 {
arch/arm64/boot/dts/nvidia/tegra186-p3509-0000+p3636-0001.dts +6 -0
@@ -712,6 +712,12 @@ usb@3550000 { phy-names = "usb2-0"; }; + cec@3960000 { + status = "okay"; + + hdmi-phandle = <&sor1>; + }; + hsp@3c00000 { status = "okay"; };
arch/arm64/boot/dts/nvidia/tegra194-p2972-0000.dts +6 -0
@@ -2121,6 +2121,12 @@ usb@3610000 { phy-names = "usb2-0", "usb2-1", "usb2-3", "usb3-0", "usb3-2", "usb3-3"; }; + cec@3960000 { + status = "okay"; + + hdmi-phandle = <&sor2>; + }; + i2c@c240000 { typec@8 { compatible = "cypress,cypd4226";
arch/arm64/boot/dts/nvidia/tegra194-p3509-0000.dtsi +6 -0
@@ -2174,6 +2174,12 @@ usb@3610000 { phy-names = "usb2-1", "usb2-2", "usb3-2"; }; + cec@3960000 { + status = "okay"; + + hdmi-phandle = <&sor1>; + }; + host1x@13e00000 { display-hub@15200000 { status = "okay";
arch/arm64/boot/dts/nvidia/tegra210-p2371-2180.dts +6 -0
@@ -90,6 +90,12 @@ eeprom@57 { }; }; + cec@70015000 { + status = "okay"; + + hdmi-phandle = <&sor1>; + }; + clock@70110000 { status = "okay";
arch/arm64/boot/dts/nvidia/tegra210-p3450-0000.dts +6 -0
@@ -419,6 +419,12 @@ pmc@7000e400 { nvidia,sys-clock-req-active-high; }; + cec@70015000 { + status = "okay"; + + hdmi-phandle = <&sor1>; + }; + hda@70030000 { nvidia,model = "NVIDIA Jetson Nano HDA";
Signature · 1 line
2.48.1
Rob Herring (Arm)
maintainerRe: [PATCH v2 1/4] media: dt-bindings: Document Tegra186 and Tegra194 cec
In reply to Aaron KlingQuoted 9 lines · Aaron Kling
These are already used in device trees, so describe them here. As the driver only declares up through Tegra210, these must use a fallback compatible of tegra210-cec.
Signed-off-by Aaron Kling <[email protected]>--- .../bindings/media/cec/nvidia,tegra114-cec.yaml | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-)
My bot found errors running 'make dt_binding_check' on your patch:
yamllint warnings/errors:./Documentation/devicetree/bindings/media/cec/nvidia,tegra114-cec.yaml:19:9: [warning] wrong indentation: expected 10 but found 8 (indentation) ./Documentation/devicetree/bindings/media/cec/nvidia,tegra114-cec.yaml:20:11: [warning] wrong indentation: expected 12 but found 10 (indentation) ./Documentation/devicetree/bindings/media/cec/nvidia,tegra114-cec.yaml:24:9: [warning] wrong indentation: expected 10 but found 8 (indentation) ./Documentation/devicetree/bindings/media/cec/nvidia,tegra114-cec.yaml:25:11: [warning] wrong indentation: expected 12 but found 10 (indentation)
dtschema/dtc warnings/errors:
doc reference errors (make refcheckdocs):
See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/[email protected]
The base for the series is generally the latest rc1. A different dependency should be noted in *this* patch.
If you already ran 'make dt_binding_check' and didn't see the above error(s), then make sure 'yamllint' is installed and dt-schema is up to date:
pip3 install dtschema --upgrade
Please check and re-submit after running the above command yourself. Note that DT_SCHEMA_FILES can be set to your schema file to speed up checking your schema. However, it must be unset to test all examples with your schema.