* [PATCH] dt-bindings: hwlock: st,stm32-hwspinlock: add mailbox cells and interrupt
@ 2026-11-25 13:52 Gerard Marull-Paretas
2026-11-25 13:57 ` sashiko-bot
0 siblings, 1 reply; 2+ messages in thread
From: Gerard Marull-Paretas @ 2026-11-25 13:52 UTC (permalink / raw)
To: Bjorn Andersson, Rob Herring, Krzysztof Kozlowski, Conor Dooley
Cc: Baolin Wang, Fabien Dessenne, Jassi Brar, Maxime Coquelin,
Alexandre Torgue, linux-remoteproc, devicetree, linux-stm32,
linux-arm-kernel
Besides locking, releasing a hardware semaphore raises the interrupt of
each core that enabled it for that semaphore. On multi-core parts
without an IPCC, such as the STM32H745/H747/H755/H757 (Cortex-M7 and
Cortex-M4), this is how the cores signal each other, each semaphore
serving as a doorbell.
Allow '#mbox-cells', its cell being the semaphore, and the interrupt of
the semaphores. Each core has an interrupt of its own (HSEM1 for the
Cortex-M7, HSEM2 for the Cortex-M4 on STM32H747), so a description
gives the one of the CPU it is for.
PebbleOS, whose STM32H747 port uses the semaphores as doorbells between
its two cores, describes and uses these.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
---
.../bindings/hwlock/st,stm32-hwspinlock.yaml | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml b/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml
index 829d1fdf4c67..3b8d872b7c21 100644
--- a/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml
+++ b/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml
@@ -9,16 +9,30 @@ title: STMicroelectronics STM32 Hardware Spinlock
maintainers:
- Fabien Dessenne <fabien.dessenne@foss.st.com>
+description: |
+ Hardware semaphores, which also ring doorbells between the cores of a
+ multi-core part: releasing a semaphore raises the interrupt of each core
+ that enabled it, and the core taking the doorbell clears it in its
+ interrupt status.
+
properties:
"#hwlock-cells":
const: 1
+ "#mbox-cells":
+ const: 1
+ description: The semaphore ringing the doorbell.
+
compatible:
const: st,stm32-hwspinlock
reg:
maxItems: 1
+ interrupts:
+ maxItems: 1
+ description: The interrupt of the semaphores for the CPU the description is for.
+
clocks:
maxItems: 1
--
2.45.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] dt-bindings: hwlock: st,stm32-hwspinlock: add mailbox cells and interrupt
2026-11-25 13:52 [PATCH] dt-bindings: hwlock: st,stm32-hwspinlock: add mailbox cells and interrupt Gerard Marull-Paretas
@ 2026-11-25 13:57 ` sashiko-bot
0 siblings, 0 replies; 2+ messages in thread
From: sashiko-bot @ 2026-11-25 13:57 UTC (permalink / raw)
To: Gerard Marull-Paretas; +Cc: devicetree, robh, conor+dt
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Low] dt-bindings: hwlock: interrupts placed before clocks in
properties
--
commit 94e93b8064cef375edbe40c9efd2a2628ce5d7ac
Author: Gerard Marull-Paretas <gerard@teslabs.com>
dt-bindings: hwlock: st,stm32-hwspinlock: add mailbox cells and interrupt
This commit adds the #mbox-cells and interrupts properties to the
st,stm32-hwspinlock DT binding schema so hardware semaphores can be
described as inter-core doorbells.
> diff --git a/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml b/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml
> index 829d1fdf4c674..3b8d872b7c21d 100644
> --- a/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml
> +++ b/Documentation/devicetree/bindings/hwlock/st,stm32-hwspinlock.yaml
> @@ -9,16 +9,30 @@ title: STMicroelectronics STM32 Hardware Spinlock
> maintainers:
> - Fabien Dessenne <fabien.dessenne@foss.st.com>
>
> +description: |
> + Hardware semaphores, which also ring doorbells between the cores of a
> + multi-core part: releasing a semaphore raises the interrupt of each core
> + that enabled it, and the core taking the doorbell clears it in its
> + interrupt status.
> +
> properties:
> "#hwlock-cells":
> const: 1
>
> + "#mbox-cells":
> + const: 1
> + description: The semaphore ringing the doorbell.
> +
> compatible:
> const: st,stm32-hwspinlock
>
> reg:
> maxItems: 1
>
> + interrupts:
> + maxItems: 1
> + description: The interrupt of the semaphores for the CPU the description is for.
> +
> clocks:
> maxItems: 1
[Severity: Low]
Should interrupts be placed after clock-names to follow the canonical DT
binding property order (compatible, reg, clocks, clock-names, interrupts)?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261125135231.98914-1-gerard@teslabs.com?part=1
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-11-25 13:57 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-25 13:52 [PATCH] dt-bindings: hwlock: st,stm32-hwspinlock: add mailbox cells and interrupt Gerard Marull-Paretas
2026-11-25 13:57 ` sashiko-bot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox