lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon,  3 Mar 2014 12:51:37 -0700
From:	Stephen Warren <swarren@...dotorg.org>
To:	Thomas Gleixner <tglx@...utronix.de>,
	Samuel Ortiz <sameo@...ux.intel.com>,
	Lee Jones <lee.jones@...aro.org>,
	Rob Herring <robh+dt@...nel.org>,
	Pawel Moll <pawel.moll@....com>,
	Mark Rutland <mark.rutland@....com>,
	Ian Campbell <ijc+devicetree@...lion.org.uk>,
	Kumar Gala <galak@...eaurora.org>
Cc:	devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
	linux-arm-kernel@...ts.infradead.org, linux-tegra@...r.kernel.org,
	Stephen Warren <swarren@...dia.com>
Subject: [PATCH V3 2/5] dt: define IRQ flags bit 4 as src/dst inversion

From: Stephen Warren <swarren@...dia.com>

Some devices have configurable IRQ output polarities. Software might
use IRQ specifier flag bits[3:0] to determine how to configure such a
device's IRQ output polarity in order to match how the IRQ controller
input is configured. If the board or SoC inverts the signal between the
device's IRQ output and controller's IRQ output, software must be
aware of this fact, in order to program the IRQ output to the correct
(i.e. opposite) polarity. This flag provides that information.

Signed-off-by: Stephen Warren <swarren@...dia.com>
---
v3: New patch.
---
 Documentation/devicetree/bindings/arm/gic.txt                     | 8 ++++++++
 .../devicetree/bindings/interrupt-controller/interrupts.txt       | 8 ++++++++
 include/dt-bindings/interrupt-controller/irq.h                    | 1 +
 3 files changed, 17 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/gic.txt b/Documentation/devicetree/bindings/arm/gic.txt
index bae0d87a38b2..b0b65a440239 100644
--- a/Documentation/devicetree/bindings/arm/gic.txt
+++ b/Documentation/devicetree/bindings/arm/gic.txt
@@ -33,6 +33,14 @@ Main node required properties:
 		2 = high-to-low edge triggered
 		4 = active high level-sensitive
 		8 = active low level-sensitive
+	bit[4] IRQ is inverted between source and sink.
+	Some devices have configurable IRQ output polarities. Software might
+	use flag bits[3:0] to determine how to configure such a device's IRQ
+	output polarity in order to match how the IRQ controller input is
+	configured. If the board or SoC inverts the signal between the
+	device's IRQ output and controller's IRQ output, software must be
+	aware of this fact, in order to program the IRQ output to the correct
+	(i.e. opposite) polarity. This flag provides that information.
 	bits[15:8] PPI interrupt cpu mask.  Each bit corresponds to each of
 	the 8 possible cpus attached to the GIC.  A bit set to '1' indicated
 	the interrupt is wired to that CPU.  Only valid for PPI interrupts.
diff --git a/Documentation/devicetree/bindings/interrupt-controller/interrupts.txt b/Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
index 1486497a24c1..636eb0f478bf 100644
--- a/Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
+++ b/Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
@@ -76,6 +76,14 @@ commonly used:
         2 = high-to-low edge triggered
         4 = active high level-sensitive
         8 = active low level-sensitive
+    - bit[4] IRQ is inverted between source and sink
+        Some devices have configurable IRQ output polarities. Software might
+        use flag bits[3:0] to determine how to configure such a device's IRQ
+        output polarity in order to match how the IRQ controller input is
+        configured. If the board or SoC inverts the signal between the
+        device's IRQ output and controller's IRQ output, software must be
+        aware of this fact, in order to program the IRQ output to the correct
+        (i.e. opposite) polarity. This flag provides that information.
 
   Example:
 
diff --git a/include/dt-bindings/interrupt-controller/irq.h b/include/dt-bindings/interrupt-controller/irq.h
index 33a1003c55aa..5b04918c5c72 100644
--- a/include/dt-bindings/interrupt-controller/irq.h
+++ b/include/dt-bindings/interrupt-controller/irq.h
@@ -15,5 +15,6 @@
 #define IRQ_TYPE_EDGE_BOTH	(IRQ_TYPE_EDGE_FALLING | IRQ_TYPE_EDGE_RISING)
 #define IRQ_TYPE_LEVEL_HIGH	4
 #define IRQ_TYPE_LEVEL_LOW	8
+#define IRQ_SRC_DST_INVERTED	16
 
 #endif
-- 
1.8.1.5

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ