Patchwork [3/9] ARM: dt: create a DT header for the GIC

login
register
mail settings
Submitter Stephen Warren
Date Feb. 13, 2013, 9:33 p.m.
Message ID <1360791198-29462-4-git-send-email-swarren@wwwdotorg.org>
Download mbox | patch
Permalink /patch/220256/
State Superseded, archived
Headers show

Comments

Stephen Warren - Feb. 13, 2013, 9:33 p.m.
From: Stephen Warren <swarren@nvidia.com>

The ARM GIC binding defines a few custom cells and flags for its IRQ
specifier. Provide names for those.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
 arch/arm/boot/dts/arm-gic.h |   17 +++++++++++++++++
 1 file changed, 17 insertions(+)
 create mode 100644 arch/arm/boot/dts/arm-gic.h

Patch

diff --git a/arch/arm/boot/dts/arm-gic.h b/arch/arm/boot/dts/arm-gic.h
new file mode 100644
index 0000000..5b1bc85
--- /dev/null
+++ b/arch/arm/boot/dts/arm-gic.h
@@ -0,0 +1,17 @@ 
+/*
+ * This header provides constants for the ARM GIC.
+ */
+
+#include "irq.h"
+
+/* interrupt specific cell 0 */
+
+#define GIC_SPI 0
+#define GIC_PPI 1
+
+/*
+ * Interrupt specifier cell 2.
+ * The flaggs in irq.h are valid, plus those below.
+ */
+#define GIC_CPU_MASK_RAW(x) ((x) << 8)
+#define GIC_CPU_MASK_SIMPLE(num) GIC_CPU_MASK_RAW((1 << (num)) - 1)