openwrt/target/linux/d1/patches-6.1/0045-dt-bindings-hwlock-sun6i-Add-interrupts-property.patch

52 lines
1.6 KiB
Diff
Raw Normal View History

From f0c29c5d370507ca2106689e7e17b81e8b58f236 Mon Sep 17 00:00:00 2001
From: Samuel Holland <samuel@sholland.org>
Date: Sun, 14 Nov 2021 11:37:34 -0600
Subject: [PATCH 045/117] dt-bindings: hwlock: sun6i: Add interrupts property
While it was not officially documented until recently (e.g. A50), the
hwspinlock block can trigger an interrupt when a lock is unlocked. This
capability is used by Allwinner's ARISC firmware, it has been verified
to work on A64, and the IRQ numbers are reserved as far back as A31.
So most likely this feature has always been available.
Even though the Linux hwspinlock framework cannot make use of the IRQ,
the capability should still be documented in the device tree.
Signed-off-by: Samuel Holland <samuel@sholland.org>
---
.../bindings/hwlock/allwinner,sun6i-a31-hwspinlock.yaml | 6 ++++++
1 file changed, 6 insertions(+)
--- a/Documentation/devicetree/bindings/hwlock/allwinner,sun6i-a31-hwspinlock.yaml
+++ b/Documentation/devicetree/bindings/hwlock/allwinner,sun6i-a31-hwspinlock.yaml
@@ -26,17 +26,22 @@ properties:
resets:
maxItems: 1
+ interrupts:
+ maxItems: 1
+
required:
- compatible
- reg
- clocks
- resets
+ - interrupts
additionalProperties: false
examples:
- |
#include <dt-bindings/clock/sun8i-a23-a33-ccu.h>
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/reset/sun8i-a23-a33-ccu.h>
hwlock@1c18000 {
@@ -44,5 +49,6 @@ examples:
reg = <0x01c18000 0x1000>;
clocks = <&ccu CLK_BUS_SPINLOCK>;
resets = <&ccu RST_BUS_SPINLOCK>;
+ interrupts = <GIC_SPI 48 IRQ_TYPE_LEVEL_HIGH>;
};
...