Devicetree
 help / color / mirror / Atom feed
From: "Shah, Tanmay" <tanmays@amd.com>
To: Ben Levinsky <blevinsk@amd.com>, Krzysztof Kozlowski <krzk@kernel.org>
Cc: "jassisinghbrar@gmail.com" <jassisinghbrar@gmail.com>,
	"andersson@kernel.org" <andersson@kernel.org>,
	"mathieu.poirier@linaro.org" <mathieu.poirier@linaro.org>,
	"robh@kernel.org" <robh@kernel.org>,
	"krzk+dt@kernel.org" <krzk+dt@kernel.org>,
	"conor+dt@kernel.org" <conor+dt@kernel.org>,
	"Simek, Michal" <michal.simek@amd.com>,
	"linux-remoteproc@vger.kernel.org"
	<linux-remoteproc@vger.kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"Shah, Tanmay" <tanmay.shah@amd.com>,
	"Levinsky, Ben" <ben.levinsky@amd.com>
Subject: Re: [PATCH 3/6] dt-bindings: mailbox: Add AMD PL Mailbox IP
Date: Thu, 15 Oct 2026 10:31:15 -0500	[thread overview]
Message-ID: <0df4bfd4-2bcc-42fd-a22d-e704e4b41d5f@amd.com> (raw)
In-Reply-To: <7067e343-24b9-4e3e-8e5e-42c98239ccae@amd.com>



On 10/15/2026 9:29 AM, Ben Levinsky wrote:
> 
>>
>>
>> *From: *Krzysztof Kozlowski <krzk@kernel.org>
>> *Date: *Thursday, October 15, 2026 at 2:46 AM
>> *To: *Levinsky, Ben <ben.levinsky@amd.com>
>> *Cc: *jassisinghbrar@gmail.com <jassisinghbrar@gmail.com>; andersson@kernel.org 
>> <andersson@kernel.org>; mathieu.poirier@linaro.org <mathieu.poirier@linaro.org>; 
>> robh@kernel.org <robh@kernel.org>; krzk+dt@kernel.org <krzk+dt@kernel.org>; 
>> conor+dt@kernel.org <conor+dt@kernel.org>; Simek, Michal <michal.simek@amd.com>; 
>> linux-remoteproc@vger.kernel.org <linux-remoteproc@vger.kernel.org>; 
>> devicetree@vger.kernel.org <devicetree@vger.kernel.org>; linux-arm- 
>> kernel@lists.infradead.org <linux-arm-kernel@lists.infradead.org>; linux- 
>> kernel@vger.kernel.org <linux-kernel@vger.kernel.org>; Shah, Tanmay 
>> <tanmay.shah@amd.com>
>> *Subject: *Re: [PATCH 3/6] dt-bindings: mailbox: Add AMD PL Mailbox IP
>>
>> On Wed, Oct 14, 2026 at 02:34:23PM -0700, Ben Levinsky wrote:
>>  > Document the AMD programmable-logic Mailbox IP used for bidirectional
>>  > FIFO communication between two processor-facing interfaces.
>>  >
>>  > The same IP is used on ZynqMP, Versal, Versal NET and Versal Gen 2.
>>  > Name each SoC in its compatible, and use amd,zynqmp-pl-mbox-2.1 as the
>>  > fallback that drivers match.
>>  >
>>  > Define the transmit and receive channel indices together with the register
>>  > aperture, interrupt, and interface clock. Describe the FIFO depth chosen
>>  > when the IP is configured, so that the driver can size received messages
>>  > to it.
>>  >
>>  > Assisted-by: LLM sparse
>>
>> How sparse assists here? It's something new. Since when does it parse
>> yaml code?
> 
>   Hi Krzysztof,
> 
>   Thank you for the review.
> 
>   You are right, sparse was not used for this patch. It was only run on
>   the C patches of the series, and I applied the same trailer to the
>   whole series by mistake. In v2 the binding patches will name only the
>   model, and the tool list will match what was actually used on each
>   patch.
> 
>>
>>  > Signed-off-by: Ben Levinsky <ben.levinsky@amd.com>
>>  > ---
>>  >  .../mailbox/amd,zynqmp-pl-mbox-2.1.yaml       | 74 +++++++++++++++++++
>>  >  1 file changed, 74 insertions(+)
>>  >  create mode 100644 Documentation/devicetree/bindings/mailbox/amd,zynqmp-pl- 
>> mbox-2.1.yaml
>>  >
>>  > diff --git a/Documentation/devicetree/bindings/mailbox/amd,zynqmp-pl- 
>> mbox-2.1.yaml b/Documentation/devicetree/bindings/mailbox/amd,zynqmp-pl- 
>> mbox-2.1.yaml
>>  > new file mode 100644
>>  > index 000000000000..2cc0d106b888
>>  > --- /dev/null
>>  > +++ b/Documentation/devicetree/bindings/mailbox/amd,zynqmp-pl-mbox-2.1.yaml
>>  > @@ -0,0 +1,74 @@
>>  > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>>  > +%YAML 1.2
>>  > +---
>>  > +$id: http://devicetree.org/schemas/mailbox/amd,zynqmp-pl-mbox-2.1.yaml# 
>> <http://devicetree.org/schemas/mailbox/amd,zynqmp-pl-mbox-2.1.yaml#>
>>  > +$schema: http://devicetree.org/meta-schemas/core.yaml# <http:// 
>> devicetree.org/meta-schemas/core.yaml#>
>>  > +
>>  > +title: AMD Programmable Logic Mailbox IP
>>  > +
>>  > +maintainers:
>>  > +  - Ben Levinsky <ben.levinsky@amd.com>
>>  > +
>>  > +description: |
>>  > +  The AMD Programmable Logic Mailbox IP provides bidirectional message passing
>>  > +  between two processor-facing interfaces. Each interface writes messages to
>>  > +  a send FIFO and reads messages from a receive FIFO. The register aperture,
>>  > +  interrupt, and clock described by a node belong to one processor-facing
>>  > +  interface. Channel 0 represents transmit and channel 1 represents receive
>>  > +  for that interface.
>>  > +
>>  > +properties:
>>  > +  compatible:
>>  > +    oneOf:
>>  > +      - const: amd,zynqmp-pl-mbox-2.1
>>
>> What is 2.1? Your SoC has different versions?
> 
>   2.1 is the version of the Mailbox IP core in the Xilinx IP catalog
>   (Mailbox v2.1). It is not a SoC version. The IP is synthesized into the
>   programmable logic, so the same core is used on every SoC, and the SoC
>   names in the compatibles do not add information.
> 
>   In v2 I will use a single IP-versioned compatible, "xlnx,mailbox-2.1",
>   and drop the SoC-specific ones. This is also the compatible the Xilinx
>   device tree generator already emits for this IP.
> 

Hi here is the reasoning behind the name:

We use 'amd' vendor prefix for all new drivers & bindings. Also, there
is dedicated IPI hardware which can be used as mailbox too, and we
should distinguish it with this PL mailbox. So I that is included in the
compatible string. (pl-mbox).

If we are also to include SOC name as well (per compatible property
guideline), then we should include one of the SOC name as well:

So, I think 'amd,zynqmp-pl-mbox-2.1' is good.

Krzysztof, are you okay with above name? The 2.1 is FPGA IP design
version number and not the SOC version number. So in future let's say
that FPGA IP design is improved then the name (pl-mbox) will remain
same, but only version number will be updated i.e. (from 2.1 to 3.0). Is
it okay if we explicitly mention this in the binding description?

Thank You.

>>
>>  > +      - items:
>>  > +          - enum:
>>  > +              - amd,versal-pl-mbox-2.1
>>  > +              - amd,versal-net-pl-mbox-2.1
>>  > +              - amd,versal2-pl-mbox-2.1
>>  > +          - const: amd,zynqmp-pl-mbox-2.1
>>  > +
>>  > +  reg:
>>  > +    maxItems: 1
>>  > +
>>  > +  interrupts:
>>  > +    maxItems: 1
>>  > +
>>  > +  clocks:
>>  > +    maxItems: 1
>>  > +
>>  > +  amd,mbox-pl-fifo-len:
>>  > +    $ref: /schemas/types.yaml#/definitions/uint32
>>  > +    minimum: 16
>>  > +    maximum: 8192
>>  > +    default: 16
>>  > +    description:
>>  > +      Depth of the send and receive FIFOs in 32-bit words, as configured by
>>  > +      the C_MAILBOX_DEPTH parameter of the IP. Must match the configured
>>  > +      depth.
>>
>> So you have multiple mailboxes per one soc different in this?
> 
>   Yes. The FIFO depth is chosen per IP instance when the design is
>   synthesized, so one design can contain several mailboxes with different
>   depths. The depth cannot be read from the registers, so the driver
>   needs it from the device tree to size its receive buffer and to limit
>   transmit messages. In v2 I will rename the property to
>   "xlnx,mailbox-depth", after the IP parameter, and state this in its

Please use 'amd' as vendor prefix, also keep pl in the property name:
i.e. 'amd,pl-mailbox-depth'.

>   description.
> 
>   Thanks,
>   Ben
> 
>>
>> Best regards,
>> Krzysztof
>>
> 


  reply	other threads:[~2026-10-15 15:31 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-14 21:34 [PATCH 0/6] Add AMD PL Mailbox and RPMsg support for the AMD BRAM remoteproc Ben Levinsky
2026-10-14 21:34 ` [PATCH 1/6] remoteproc: amd_mbv_bram: Bound device name formatting Ben Levinsky
2026-10-14 21:48   ` sashiko-bot
2026-10-14 21:34 ` [PATCH 2/6] remoteproc: amd_mbv_bram: Restore reset GPIO direction after PL reconfig Ben Levinsky
2026-10-14 21:44   ` sashiko-bot
2026-10-14 21:34 ` [PATCH 3/6] dt-bindings: mailbox: Add AMD PL Mailbox IP Ben Levinsky
2026-10-15  9:46   ` Krzysztof Kozlowski
     [not found]     ` <DM4PR12MB644859F1CA3A936684A3338B839C2@DM4PR12MB6448.namprd12.prod.outlook.com>
2026-10-15 14:29       ` Ben Levinsky
2026-10-15 15:31         ` Shah, Tanmay [this message]
2026-10-14 21:34 ` [PATCH 4/6] mailbox: Add AMD PL Mailbox soft IP controller Ben Levinsky
2026-10-14 21:41   ` sashiko-bot
2026-10-15  9:48   ` Krzysztof Kozlowski
     [not found]     ` <DM4PR12MB6448B4B18D0B45CCA678814F839C2@DM4PR12MB6448.namprd12.prod.outlook.com>
2026-10-15 14:30       ` Ben Levinsky
2026-10-14 21:34 ` [PATCH 5/6] dt-bindings: remoteproc: Add RPMsg resources to AMD BRAM rproc Ben Levinsky
2026-10-15  9:49   ` Krzysztof Kozlowski
     [not found]     ` <DM4PR12MB64480F027338BA7A1EF91E17839C2@DM4PR12MB6448.namprd12.prod.outlook.com>
2026-10-15 14:32       ` Ben Levinsky
2026-10-14 21:34 ` [PATCH 6/6] remoteproc: amd_mbv_bram: Add RPMsg support Ben Levinsky
2026-10-14 21:45   ` sashiko-bot
2026-10-15  9:51   ` Krzysztof Kozlowski
     [not found]     ` <DM4PR12MB6448FDE3208DB753A37EF3F9839C2@DM4PR12MB6448.namprd12.prod.outlook.com>
2026-10-15 14:33       ` Ben Levinsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0df4bfd4-2bcc-42fd-a22d-e704e4b41d5f@amd.com \
    --to=tanmays@amd.com \
    --cc=andersson@kernel.org \
    --cc=ben.levinsky@amd.com \
    --cc=blevinsk@amd.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jassisinghbrar@gmail.com \
    --cc=krzk+dt@kernel.org \
    --cc=krzk@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-remoteproc@vger.kernel.org \
    --cc=mathieu.poirier@linaro.org \
    --cc=michal.simek@amd.com \
    --cc=robh@kernel.org \
    --cc=tanmay.shah@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox