Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Ho Jie Feng" <hjf3108@gmail.com>
Cc: devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH 5/5] ARM: dts: bcm47622: Add SPU-M crypto engine and PDC mailbox
Date: Sat, 05 Dec 2026 09:05:15 +0000	[thread overview]
Message-ID: <sashiko-outbox-251334@kernel.org> (raw)
In-Reply-To: <20261205084221.1564842-6-hjf3108@gmail.com>

Thank you for your contribution! Sashiko AI review found 3 potential
issues to consider:
- [Medium] ARM: dts: bcm47622: PDC and SPU-M drivers unselectable under
  ARCH_BCMBCA
- [Medium] dts: bcm47622: brcm,rx-status-len set to 4 instead of 32 for
  SPU-M PDC
- [Low] dts: bcm47622: MMIO mailbox and crypto nodes placed directly
  under root
--

commit 9b37dffc02320c47556912541d2497ae711c3692
Author: Ho Jie Feng <hjf3108@gmail.com>

ARM: dts: bcm47622: Add SPU-M crypto engine and PDC mailbox

This commit adds the iProc PDC mailbox and SPU-M symmetric crypto engine
nodes to the BCM47622 devicetree include file.

> diff --git a/arch/arm/boot/dts/broadcom/bcm47622.dtsi b/arch/arm/boot/dts/broadcom/bcm47622.dtsi
> index 182ec9bcd3411..60e1f556a1654 100644
> --- a/arch/arm/boot/dts/broadcom/bcm47622.dtsi
> +++ b/arch/arm/boot/dts/broadcom/bcm47622.dtsi
> @@ -102,6 +102,21 @@ psci {
>  		method = "smc";
>  	};
>  
> +	pdc: mailbox@8001c000 {
> +		compatible = "brcm,iproc-pdc-mbox";
> +		reg = <0x8001c000 0x448>;
> +		interrupts = <GIC_SPI 91 IRQ_TYPE_LEVEL_HIGH>;
> +		#mbox-cells = <1>;
> +		brcm,rx-status-len = <4>;
> +		brcm,use-bcm-hdr;

[Severity: Medium]
Should brcm,rx-status-len be 32 instead of 4 here?

Every other in-tree PDC/FA2 node paired with brcm,spum-crypto and
brcm,use-bcm-hdr (in ns2.dtsi, bcm-nsp.dtsi, and the binding example)
uses 32, matching PDC_SPUM_RESP_HDR_LEN in bcm-pdc-mailbox.c rather than
the 4-byte trailing SPU_RX_STATUS_LEN.

With 4, pdc_rx_buf_pool_create() sizes pdc_resp_hdr_len to 12 bytes
instead of 40 and pdc_ring_init() programs RcvOffset to 4.  If BCM47622
hardware prepends a 32-byte DMA RX status header like other SPU-M PDC
integrations, RX metadata will spill into dst_sg and corrupt responses.

> +	};
> +
> +	crypto@8001d000 {
> +		compatible = "brcm,spum-crypto";
> +		reg = <0x8001d000 0x64>;
> +		mboxes = <&pdc 0>;
> +	};

[Severity: Medium]
Can the matching drivers for these nodes be selected on ARCH_BCMBCA?

bcm947622.dtb is built under ARCH_BCMBCA, which does not select
ARCH_BCM_IPROC.  CRYPTO_DEV_BCM_SPU depends on ARCH_BCM_IPROC and
BCM_PDC_MBOX depends on ARCH_BCM_IPROC || COMPILE_TEST, so a standalone
ARCH_BCMBCA build cannot enable these drivers without Kconfig updates.

> +
>  	axi@81000000 {
>  		compatible = "simple-bus";
>  		#address-cells = <1>;

[Severity: Low]
Would it be better to place mailbox@8001c000 and crypto@8001d000 inside
a simple-bus container node rather than directly under the root node?

Documentation/devicetree/bindings/writing-bindings.rst recommends
placing all MMIO devices under a bus node, matching axi@81000000 and the
other BCMBCA SoC DTSI files.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261205084221.1564842-1-hjf3108@gmail.com?part=5

      reply	other threads:[~2026-12-05  9:05 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-05  8:42 [PATCH 0/5] ARM: dts: bcm47622: Add RNG, GPIO, I2C, DMA and crypto blocks Ho Jie Feng
2026-12-05  8:42 ` [PATCH 1/5] ARM: dts: bcm47622: Add iproc rng Ho Jie Feng
2026-12-05  8:42 ` [PATCH 2/5] ARM: dts: bcm47622: Add GPIO blocks Ho Jie Feng
2026-12-05  8:42 ` [PATCH 3/5] ARM: dts: bcm47622: Add I2C bus block Ho Jie Feng
2026-12-05  8:42 ` [PATCH 4/5] ARM: dts: bcm47622: Add ARM PL081 DMA block Ho Jie Feng
2026-12-05  8:42 ` [PATCH 5/5] ARM: dts: bcm47622: Add SPU-M crypto engine and PDC mailbox Ho Jie Feng
2026-12-05  9:05   ` sashiko-bot [this message]

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=sashiko-outbox-251334@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=hjf3108@gmail.com \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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