public inbox for devicetree@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA
@ 2026-03-21 21:20 Atharv Dubey
  2026-03-21 22:33 ` Rob Herring (Arm)
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Atharv Dubey @ 2026-03-21 21:20 UTC (permalink / raw)
  To: Jassi Brar, Rob Herring, Krzysztof Kozlowski, Conor Dooley
  Cc: Jassi Brar, linux-kernel, devicetree, Atharv Dubey

Convert the Generic Mailbox Controller and Client
binding from text format to DT schema format.

Signed-off-by: Atharv Dubey <atharvd440@gmail.com>
---
 .../devicetree/bindings/mailbox/mailbox.txt        | 60 -----------------
 .../devicetree/bindings/mailbox/mailbox.yaml       | 78 ++++++++++++++++++++++
 2 files changed, 78 insertions(+), 60 deletions(-)

diff --git a/Documentation/devicetree/bindings/mailbox/mailbox.txt b/Documentation/devicetree/bindings/mailbox/mailbox.txt
deleted file mode 100644
index af8ecee2ac68..000000000000
--- a/Documentation/devicetree/bindings/mailbox/mailbox.txt
+++ /dev/null
@@ -1,60 +0,0 @@
-* Generic Mailbox Controller and client driver bindings
-
-Generic binding to provide a way for Mailbox controller drivers to
-assign appropriate mailbox channel to client drivers.
-
-* Mailbox Controller
-
-Required property:
-- #mbox-cells: Must be at least 1. Number of cells in a mailbox
-		specifier.
-
-Example:
-	mailbox: mailbox {
-		...
-		#mbox-cells = <1>;
-	};
-
-
-* Mailbox Client
-
-Required property:
-- mboxes: List of phandle and mailbox channel specifiers.
-
-Optional property:
-- mbox-names: List of identifier strings for each mailbox channel.
-- shmem : List of phandle pointing to the shared memory(SHM) area between the
-	  users of these mailboxes for IPC, one for each mailbox. This shared
-	  memory can be part of any memory reserved for the purpose of this
-	  communication between the mailbox client and the remote.
-
-
-Example:
-	pwr_cntrl: power {
-		...
-		mbox-names = "pwr-ctrl", "rpc";
-		mboxes = <&mailbox 0 &mailbox 1>;
-	};
-
-Example with shared memory(shmem):
-
-	sram: sram@50000000 {
-		compatible = "mmio-sram";
-		reg = <0x50000000 0x10000>;
-
-		#address-cells = <1>;
-		#size-cells = <1>;
-		ranges = <0 0x50000000 0x10000>;
-
-		cl_shmem: shmem@0 {
-			compatible = "client-shmem";
-			reg = <0x0 0x200>;
-		};
-	};
-
-	client@2e000000 {
-		...
-		mboxes = <&mailbox 0>;
-		shmem = <&cl_shmem>;
-		..
-	};
diff --git a/Documentation/devicetree/bindings/mailbox/mailbox.yaml b/Documentation/devicetree/bindings/mailbox/mailbox.yaml
new file mode 100644
index 000000000000..856386f076b4
--- /dev/null
+++ b/Documentation/devicetree/bindings/mailbox/mailbox.yaml
@@ -0,0 +1,78 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mailbox/mailbox.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Generic Mailbox Controller and Client
+
+maintainers:
+  - Jassi Brar <jaswinder.singh@linaro.org>
+
+description:
+  Generic binding to provide a way for Mailbox controller drivers to
+  assign appropriate mailbox channel to client drivers.
+
+select: false
+
+properties:
+  "#mbox-cells":
+    minimum: 1
+    description:
+      Number of cells in a mailbox specifier. Must be at least 1.
+
+  mboxes:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description:
+      List of phandle and mailbox channel specifiers.
+
+  mbox-names:
+    $ref: /schemas/types.yaml#/definitions/string-array
+    description:
+      List of identifier strings for each mailbox channel.
+
+  shmem:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description:
+      List of phandles pointing to the shared memory (SHM) area between the
+      users of these mailboxes for IPC, one for each mailbox. This shared
+      memory can be part of any memory reserved for the purpose of this
+      communication between the mailbox client and the remote.
+
+additionalProperties: true
+
+examples:
+  # Mailbox Controller
+  - |
+    mailbox: mailbox {
+        #mbox-cells = <1>;
+    };
+
+  # Mailbox Client
+  - |
+    pwr_cntrl: power {
+        mbox-names = "pwr-ctrl", "rpc";
+        mboxes = <&mailbox 0>, <&mailbox 1>;
+    };
+
+  # Mailbox Client with shared memory
+  - |
+    sram: sram@50000000 {
+        compatible = "mmio-sram";
+        reg = <0x50000000 0x10000>;
+
+        #address-cells = <1>;
+        #size-cells = <1>;
+        ranges = <0 0x50000000 0x10000>;
+
+        cl_shmem: scmi-sram@0 {
+            compatible = "arm,scmi-shmem";
+            reg = <0x0 0x200>;
+        };
+    };
+
+    client@2e000000 {
+        reg = <0x2e000000 0x400>;
+        mboxes = <&mailbox 0>;
+        shmem = <&cl_shmem>;
+    };

---
base-commit: c612261bedd6bbab7109f798715e449c9d20ff2f
change-id: 20260322-mailbox-16faf3717cfe

Best regards,
-- 
Atharv Dubey <atharvd440@gmail.com>


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA
  2026-03-21 21:20 [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA Atharv Dubey
@ 2026-03-21 22:33 ` Rob Herring (Arm)
  2026-03-22  6:05 ` kernel test robot
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Rob Herring (Arm) @ 2026-03-21 22:33 UTC (permalink / raw)
  To: Atharv Dubey
  Cc: Jassi Brar, linux-kernel, Conor Dooley, Krzysztof Kozlowski,
	devicetree, Jassi Brar


On Sun, 22 Mar 2026 02:50:01 +0530, Atharv Dubey wrote:
> Convert the Generic Mailbox Controller and Client
> binding from text format to DT schema format.
> 
> Signed-off-by: Atharv Dubey <atharvd440@gmail.com>
> ---
>  .../devicetree/bindings/mailbox/mailbox.txt        | 60 -----------------
>  .../devicetree/bindings/mailbox/mailbox.yaml       | 78 ++++++++++++++++++++++
>  2 files changed, 78 insertions(+), 60 deletions(-)
> 

My bot found errors running 'make dt_binding_check' on your patch:

yamllint warnings/errors:

dtschema/dtc warnings/errors:


doc reference errors (make refcheckdocs):
Warning: Documentation/devicetree/bindings/mailbox/altera-mailbox.txt references a file that doesn't exist: Documentation/devicetree/bindings/mailbox/mailbox.txt
Warning: Documentation/devicetree/bindings/mailbox/ti,omap-mailbox.yaml references a file that doesn't exist: Documentation/devicetree/bindings/mailbox/mailbox.txt
Warning: Documentation/devicetree/bindings/power/reset/xlnx,zynqmp-power.yaml references a file that doesn't exist: Documentation/devicetree/bindings/mailbox/mailbox.txt
Documentation/devicetree/bindings/mailbox/altera-mailbox.txt: Documentation/devicetree/bindings/mailbox/mailbox.txt
Documentation/devicetree/bindings/mailbox/ti,omap-mailbox.yaml: Documentation/devicetree/bindings/mailbox/mailbox.txt
Documentation/devicetree/bindings/power/reset/xlnx,zynqmp-power.yaml: Documentation/devicetree/bindings/mailbox/mailbox.txt

See https://patchwork.kernel.org/project/devicetree/patch/20260322-mailbox-v1-1-c6251f18187c@gmail.com

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.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA
  2026-03-21 21:20 [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA Atharv Dubey
  2026-03-21 22:33 ` Rob Herring (Arm)
@ 2026-03-22  6:05 ` kernel test robot
  2026-03-22  9:00 ` Krzysztof Kozlowski
  2026-03-23 13:35 ` Rob Herring
  3 siblings, 0 replies; 6+ messages in thread
From: kernel test robot @ 2026-03-22  6:05 UTC (permalink / raw)
  To: Atharv Dubey, Jassi Brar, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: oe-kbuild-all, linux-kernel, devicetree, Atharv Dubey

Hi Atharv,

kernel test robot noticed the following build warnings:

[auto build test WARNING on c612261bedd6bbab7109f798715e449c9d20ff2f]

url:    https://github.com/intel-lab-lkp/linux/commits/Atharv-Dubey/mailbox-dt-bindings-mailbox-Convert-to-DT-SCHEMA/20260322-075100
base:   c612261bedd6bbab7109f798715e449c9d20ff2f
patch link:    https://lore.kernel.org/r/20260322-mailbox-v1-1-c6251f18187c%40gmail.com
patch subject: [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
docutils: docutils (Docutils 0.21.2, Python 3.13.5, on linux)
reproduce: (https://download.01.org/0day-ci/archive/20260322/202603220726.FnGA4Rwp-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202603220726.FnGA4Rwp-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> Warning: Documentation/devicetree/bindings/mailbox/altera-mailbox.txt references a file that doesn't exist: Documentation/devicetree/bindings/mailbox/mailbox.txt
>> Warning: Documentation/devicetree/bindings/mailbox/ti,omap-mailbox.yaml references a file that doesn't exist: Documentation/devicetree/bindings/mailbox/mailbox.txt
   Warning: Documentation/devicetree/bindings/mfd/motorola-cpcap.txt references a file that doesn't exist: Documentation/devicetree/bindings/rtc/cpcap-rtc.txt
>> Warning: Documentation/devicetree/bindings/power/reset/xlnx,zynqmp-power.yaml references a file that doesn't exist: Documentation/devicetree/bindings/mailbox/mailbox.txt
   Warning: Documentation/devicetree/bindings/regulator/siliconmitus,sm5703-regulator.yaml references a file that doesn't exist: Documentation/devicetree/bindings/mfd/siliconmitus,sm5703.yaml
   Warning: Documentation/devicetree/bindings/rtc/motorola,cpcap-rtc.yaml references a file that doesn't exist: Documentation/devicetree/bindings/mfd/motorola,cpcap.yaml
   Warning: Documentation/doc-guide/parse-headers.rst references a file that doesn't exist: Documentation/userspace-api/media/Makefile
   Warning: Documentation/leds/leds-lp5812.rst references a file that doesn't exist: Documentation/ABI/testing/sysfs-class-led-multicolor.rst
   Warning: Documentation/translations/it_IT/doc-guide/parse-headers.rst references a file that doesn't exist: Documentation/userspace-api/media/Makefile

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA
  2026-03-21 21:20 [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA Atharv Dubey
  2026-03-21 22:33 ` Rob Herring (Arm)
  2026-03-22  6:05 ` kernel test robot
@ 2026-03-22  9:00 ` Krzysztof Kozlowski
  2026-03-23 13:35 ` Rob Herring
  3 siblings, 0 replies; 6+ messages in thread
From: Krzysztof Kozlowski @ 2026-03-22  9:00 UTC (permalink / raw)
  To: Atharv Dubey, Jassi Brar, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: Jassi Brar, linux-kernel, devicetree

On 21/03/2026 22:20, Atharv Dubey wrote:
> Convert the Generic Mailbox Controller and Client
> binding from text format to DT schema format.
> 
> Signed-off-by: Atharv Dubey <atharvd440@gmail.com>
> ---
>  .../devicetree/bindings/mailbox/mailbox.txt        | 60 -----------------
>  .../devicetree/bindings/mailbox/mailbox.yaml       | 78 ++++++++++++++++++++++
>  2 files changed, 78 insertions(+), 60 deletions(-)

Isn't the binding in general already converted in dtschema?

...
> +
> +maintainers:
> +  - Jassi Brar <jaswinder.singh@linaro.org>
> +
> +description:
> +  Generic binding to provide a way for Mailbox controller drivers to
> +  assign appropriate mailbox channel to client drivers.
> +
> +select: false

What is the point in such case? This patch makes little sense. If there
is useful text, it should be moved to dtschema. Unless it is already
there. And only after getting acks for relicensing.

But I cannot find anything useful here, so this file should stay only
for the purpose of providing context.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA
  2026-03-21 21:20 [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA Atharv Dubey
                   ` (2 preceding siblings ...)
  2026-03-22  9:00 ` Krzysztof Kozlowski
@ 2026-03-23 13:35 ` Rob Herring
  2026-03-23 14:28   ` Atharv Dubey
  3 siblings, 1 reply; 6+ messages in thread
From: Rob Herring @ 2026-03-23 13:35 UTC (permalink / raw)
  To: Atharv Dubey
  Cc: Jassi Brar, Krzysztof Kozlowski, Conor Dooley, Jassi Brar,
	linux-kernel, devicetree

On Sat, Mar 21, 2026 at 4:20 PM Atharv Dubey <atharvd440@gmail.com> wrote:
>
> Convert the Generic Mailbox Controller and Client
> binding from text format to DT schema format.
>
> Signed-off-by: Atharv Dubey <atharvd440@gmail.com>
> ---
>  .../devicetree/bindings/mailbox/mailbox.txt        | 60 -----------------
>  .../devicetree/bindings/mailbox/mailbox.yaml       | 78 ++++++++++++++++++++++
>  2 files changed, 78 insertions(+), 60 deletions(-)

This already exists within dtschema with other core schemas. Probably
some of the description is missing, but moving those requires
re-licensing permission from the original authors.

Rob

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA
  2026-03-23 13:35 ` Rob Herring
@ 2026-03-23 14:28   ` Atharv Dubey
  0 siblings, 0 replies; 6+ messages in thread
From: Atharv Dubey @ 2026-03-23 14:28 UTC (permalink / raw)
  To: Rob Herring
  Cc: Jassi Brar, Krzysztof Kozlowski, Conor Dooley, Jassi Brar,
	linux-kernel, devicetree

Hi Krzysztof & Rob,

Thanks for the review. I agree with krzysztof on this, it just serves as 
a generic guideline for the

mailbox controller. Dropping this would make sense.

Regards,
Atharv

  On 3/23/26 19:05, Rob Herring wrote:
> On Sat, Mar 21, 2026 at 4:20 PM Atharv Dubey <atharvd440@gmail.com> wrote:
>> Convert the Generic Mailbox Controller and Client
>> binding from text format to DT schema format.
>>
>> Signed-off-by: Atharv Dubey <atharvd440@gmail.com>
>> ---
>>   .../devicetree/bindings/mailbox/mailbox.txt        | 60 -----------------
>>   .../devicetree/bindings/mailbox/mailbox.yaml       | 78 ++++++++++++++++++++++
>>   2 files changed, 78 insertions(+), 60 deletions(-)
> This already exists within dtschema with other core schemas. Probably
> some of the description is missing, but moving those requires
> re-licensing permission from the original authors.
>
> Rob

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2026-03-23 14:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-21 21:20 [PATCH] mailbox: dt-bindings: mailbox: Convert to DT-SCHEMA Atharv Dubey
2026-03-21 22:33 ` Rob Herring (Arm)
2026-03-22  6:05 ` kernel test robot
2026-03-22  9:00 ` Krzysztof Kozlowski
2026-03-23 13:35 ` Rob Herring
2026-03-23 14:28   ` Atharv Dubey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox