From eae9dc59c19b5e11613192c3fa031fddd6e56ec9 Mon Sep 17 00:00:00 2001 From: Ketan Patil Date: Wed, 5 Mar 2025 08:37:33 +0000 Subject: [PATCH] devicetree: bindings: Update DT binding doc - Fsi, generic and VPR carveouts follow the reserved-memory DT binding provided by linux kernel. Hence delete these unnecessary DT binding files. - Rename nvidia,carveouts-t19x.yaml file to nvidia,carveouts.yaml - Update compatible string for tegra-carveouts. - Add missing properties like disable-debug-support, memory-region for tegra-carveouts. JIRA TMM-6011 Change-Id: I857578bc9e8598cb4ec7a7fb314089d2f78d6950 Signed-off-by: Ketan Patil Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3312820 Reviewed-by: Pritesh Raithatha GVS: buildbot_gerritrpt --- .../bindings/misc/nvidia,fsi-carveout.yaml | 100 ------------------ .../misc/nvidia,generic_carveout.yaml | 80 -------------- .../tegra/nvmap/nvidia,carveouts-t19x.yaml | 55 ---------- .../video/tegra/nvmap/nvidia,carveouts.yaml | 73 +++++++++++++ .../tegra/nvmap/nvidia,vpr-carveout.yaml | 51 --------- .../tegra/nvmap/nvidia,vpr1-carveout.yaml | 51 --------- 6 files changed, 73 insertions(+), 337 deletions(-) delete mode 100644 Documentation/devicetree/bindings/misc/nvidia,fsi-carveout.yaml delete mode 100644 Documentation/devicetree/bindings/misc/nvidia,generic_carveout.yaml delete mode 100644 Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts-t19x.yaml create mode 100644 Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts.yaml delete mode 100644 Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr-carveout.yaml delete mode 100644 Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr1-carveout.yaml diff --git a/Documentation/devicetree/bindings/misc/nvidia,fsi-carveout.yaml b/Documentation/devicetree/bindings/misc/nvidia,fsi-carveout.yaml deleted file mode 100644 index 8f1312c6..00000000 --- a/Documentation/devicetree/bindings/misc/nvidia,fsi-carveout.yaml +++ /dev/null @@ -1,100 +0,0 @@ -# Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# -# This program is free software; you can redistribute it and/or modify it -# under the terms and conditions of the GNU General Public License, -# version 2, as published by the Free Software Foundation. -# -# This program is distributed in the hope it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -# more details. - -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/fsi-carveout/nvidia,fsi-carveout.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Nvidia FSI Carveout - -maintainers: - - Sachin Nikam - -description: | - The following nodes use this compatibility - - /reserved-memory/fsi-carveout - -select: - properties: - compatible: - minItems: 1 - maxItems: 1 - items: - enum: - - nvidia,fsi-carveout - - required: - - compatible - -properties: - - size: - $ref: "/schemas/types.yaml#/definitions/uint32-matrix" - items: - minItems: 2 - maxItems: 2 - items: - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x0 - maximum: 0x0 - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x2000000 - maximum: 0x2000000 - - alignment: - $ref: "/schemas/types.yaml#/definitions/uint32-matrix" - items: - minItems: 2 - maxItems: 2 - items: - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x0 - maximum: 0x0 - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x1000 - maximum: 0x1000 - - no-map: - $ref: "/schemas/types.yaml#/definitions/flag" - - alloc-ranges: - $ref: "/schemas/types.yaml#/definitions/uint32-matrix" - items: - minItems: 4 - maxItems: 4 - items: - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x0 - maximum: 0x0 - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x0 - maximum: 0x0 - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x1 - maximum: 0x1 - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x0 - maximum: 0x0 - -required: - - compatible - -examples: - - | - fsi-carveout { - compatible = "nvidia,fsi-carveout"; - status = "disabled"; - size = <0 0x2000000>; - alignment = <0 0x1000>; - no-map; - alloc-ranges = <0x0 0x0 0x1 0x0>; - }; diff --git a/Documentation/devicetree/bindings/misc/nvidia,generic_carveout.yaml b/Documentation/devicetree/bindings/misc/nvidia,generic_carveout.yaml deleted file mode 100644 index 4e24da68..00000000 --- a/Documentation/devicetree/bindings/misc/nvidia,generic_carveout.yaml +++ /dev/null @@ -1,80 +0,0 @@ -# Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# -# This program is free software; you can redistribute it and/or modify it -# under the terms and conditions of the GNU General Public License, -# version 2, as published by the Free Software Foundation. -# -# This program is distributed in the hope it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -# more details. - -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/generic_carveout/nvidia,generic_carveout.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Nvidia Generic Carveout - -maintainers: - - Sachin Nikam - -description: | - The following nodes use this compatibility - - /reserved-memory/generic_carveout - -select: - properties: - compatible: - minItems: 1 - maxItems: 1 - items: - enum: - - nvidia,generic_carveout - - required: - - compatible - -properties: - - size: - $ref: "/schemas/types.yaml#/definitions/uint32-matrix" - items: - minItems: 2 - maxItems: 2 - items: - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x0 - maximum: 0x0 - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x40000000 - maximum: 0x40000000 - - alignment: - $ref: "/schemas/types.yaml#/definitions/uint32-matrix" - items: - minItems: 2 - maxItems: 2 - items: - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x0 - maximum: 0x0 - - $ref: "/schemas/types.yaml#/definitions/uint32" - minimum: 0x200000 - maximum: 0x200000 - - no-map: - $ref: "/schemas/types.yaml#/definitions/flag" - -required: - - compatible - -examples: - - | - generic_carveout { - compatible = "nvidia,generic_carveout"; - status = "disabled"; - size = <0 0x40000000>; - alignment = <0 0x200000>; - no-map; - }; diff --git a/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts-t19x.yaml b/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts-t19x.yaml deleted file mode 100644 index 7ccea29e..00000000 --- a/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts-t19x.yaml +++ /dev/null @@ -1,55 +0,0 @@ -# Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# -# This program is free software; you can redistribute it and/or modify it -# under the terms and conditions of the GNU General Public License, -# version 2, as published by the Free Software Foundation. -# -# This program is distributed in the hope it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -# more details. - -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/tegra-carveouts/nvidia,carveouts-t19x.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Nvidia Tegra Memory Management Driver - -maintainers: - - Ketan Patil - -description: | - the compatability = nvidia,carveouts-t19x is mentioned in the following drivers - - /kernel/nvidia-oot/drivers/video/tegra/nvmap/nvmap_init.c - - The following nodes use this compatibility - - /tegra-carveouts - -select: - properties: - compatible: - minItems: 1 - maxItems: 1 - items: - enum: - - nvidia,carveouts-t19x - - required: - - compatible - -properties: - - dont-convert-iovmm-to-carveout: - $ref: "/schemas/types.yaml#/definitions/flag" - -required: - - compatible - -examples: - - | - tegra-carveouts { - compatible = "nvidia,carveouts-t19x"; - memory-region = <&vpr &fsi_reserved &vpr1>; - status = "disabled"; - }; diff --git a/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts.yaml b/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts.yaml new file mode 100644 index 00000000..2ec2dbb9 --- /dev/null +++ b/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,carveouts.yaml @@ -0,0 +1,73 @@ +# Copyright (c) 2024-2025, NVIDIA CORPORATION & AFFILIATES. All rights reserved. +# +# This program is free software; you can redistribute it and/or modify it +# under the terms and conditions of the GNU General Public License, +# version 2, as published by the Free Software Foundation. +# +# This program is distributed in the hope it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +# more details. + +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/tegra-carveouts/nvidia,carveouts.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Nvidia Tegra Memory Management Driver + +maintainers: + - Ketan Patil + +description: | + This schema defines the properties for the NVIDIA Tegra carveouts nodes. + +select: + properties: + compatible: + minItems: 1 + maxItems: 1 + items: + enum: + - nvidia,carveouts + + required: + - compatible + +properties: + + dont-convert-iovmm-to-carveout: + description: | + If enabled, the nvmap will not convert iovmm to carveout. This property is necessary + when generic carveout is enabled and iovmm memory should not be converted to carveout. + $ref: "/schemas/types.yaml#/definitions/flag" + + disable-debug-support: + description: | + If enabled, the nvmap will not support debug APIs. + $ref: "/schemas/types.yaml#/definitions/flag" + + memory-region: + description: | + A list of phandles to carveout nodes. + $ref: "/schemas/types.yaml#/definitions/phandle-array" + + status: + description: | + The status of the carveouts node. + enum: + - okay + - disabled + +required: + - compatible + +examples: + - | + tegra-carveouts { + compatible = "nvidia,carveouts"; + dont-convert-iovmm-to-carveout; + memory-region = <&generic_reserved &fsi_reserved>; + disable-debug-support; + status = "okay"; + }; diff --git a/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr-carveout.yaml b/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr-carveout.yaml deleted file mode 100644 index af2c655f..00000000 --- a/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr-carveout.yaml +++ /dev/null @@ -1,51 +0,0 @@ -# Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# -# This program is free software; you can redistribute it and/or modify it -# under the terms and conditions of the GNU General Public License, -# version 2, as published by the Free Software Foundation. -# -# This program is distributed in the hope it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -# more details. - -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/vpr-carveout/nvidia,vpr-carveout.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Nvidia Tegra Memory Management Driver - -maintainers: - - Ketan Patil - -description: | - the compatability = nvidia,vpr-carveout is mentioned in the following drivers - - /kernel/nvidia-oot/drivers/video/tegra/nvmap/nvmap_init.c - - The following nodes use this compatibility - - /reserved-memory/vpr-carveout - -select: - properties: - compatible: - minItems: 1 - maxItems: 1 - items: - enum: - - nvidia,vpr-carveout - - required: - - compatible - -properties: - -required: - - compatible - -examples: - - | - vpr-carveout { - compatible = "nvidia,vpr-carveout"; - status = "disabled"; - }; diff --git a/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr1-carveout.yaml b/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr1-carveout.yaml deleted file mode 100644 index b95f2d8d..00000000 --- a/Documentation/devicetree/bindings/video/tegra/nvmap/nvidia,vpr1-carveout.yaml +++ /dev/null @@ -1,51 +0,0 @@ -# Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# -# This program is free software; you can redistribute it and/or modify it -# under the terms and conditions of the GNU General Public License, -# version 2, as published by the Free Software Foundation. -# -# This program is distributed in the hope it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -# more details. - -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/vpr1-carveout/nvidia,vpr1-carveout.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Nvidia Tegra Memory Management Driver - -maintainers: - - Ketan Patil - -description: | - the compatability = nvidia,vpr1-carveout is mentioned in the following drivers - - /kernel/nvidia-oot/drivers/video/tegra/nvmap/nvmap_init.c - - The following nodes use this compatibility - - /reserved-memory/vpr1-carveout - -select: - properties: - compatible: - minItems: 1 - maxItems: 1 - items: - enum: - - nvidia,vpr1-carveout - - required: - - compatible - -properties: - -required: - - compatible - -examples: - - | - vpr1-carveout { - compatible = "nvidia,vpr1-carveout"; - status = "disabled"; - };