]> nv-tegra.nvidia Code Review - linux-3.10.git/commitdiff
[IA64-SGI] Shub2 provides an addition of 2 External Interrupt events.
authorColin Ngam <cngam@sgi.com>
Mon, 25 Apr 2005 20:06:28 +0000 (13:06 -0700)
committerTony Luck <tony.luck@intel.com>
Mon, 25 Apr 2005 20:06:28 +0000 (13:06 -0700)
Signed-off-by: Colin Ngam <cngam@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
arch/ia64/sn/kernel/irq.c
include/asm-ia64/sn/shub_mmr.h

index b52d32975f2b18632886cdded24bbcda7c7a0b35..0f4e8138658f2cb0ac1ce5757736906f8d7ba0b6 100644 (file)
@@ -82,20 +82,9 @@ static void sn_ack_irq(unsigned int irq)
        nasid = get_nasid();
        event_occurred =
            HUB_L((uint64_t *) GLOBAL_MMR_ADDR(nasid, SH_EVENT_OCCURRED));
-       if (event_occurred & SH_EVENT_OCCURRED_UART_INT_MASK) {
-               mask |= (1 << SH_EVENT_OCCURRED_UART_INT_SHFT);
-       }
-       if (event_occurred & SH_EVENT_OCCURRED_IPI_INT_MASK) {
-               mask |= (1 << SH_EVENT_OCCURRED_IPI_INT_SHFT);
-       }
-       if (event_occurred & SH_EVENT_OCCURRED_II_INT0_MASK) {
-               mask |= (1 << SH_EVENT_OCCURRED_II_INT0_SHFT);
-       }
-       if (event_occurred & SH_EVENT_OCCURRED_II_INT1_MASK) {
-               mask |= (1 << SH_EVENT_OCCURRED_II_INT1_SHFT);
-       }
+       mask = event_occurred & SH_ALL_INT_MASK;
        HUB_S((uint64_t *) GLOBAL_MMR_ADDR(nasid, SH_EVENT_OCCURRED_ALIAS),
-             mask);
+                mask);
        __set_bit(irq, (volatile void *)pda->sn_in_service_ivecs);
 
        move_irq(irq);
index 5c2fcf13d5ced021ac48eca47d68721b5f4f3083..6ec37e816a9ebdc5870880d8d26b9251378dcf51 100644 (file)
 #define SH_EVENT_OCCURRED_II_INT1_SHFT           30
 #define SH_EVENT_OCCURRED_II_INT1_MASK           0x0000000040000000
 
+/*   SH2_EVENT_OCCURRED_EXTIO_INT2                                      */
+/*   Description:  Pending SHUB 2 EXT IO INT2                           */
+#define SH2_EVENT_OCCURRED_EXTIO_INT2_SHFT       33
+#define SH2_EVENT_OCCURRED_EXTIO_INT2_MASK       0x0000000200000000
+
+/*   SH2_EVENT_OCCURRED_EXTIO_INT3                                      */
+/*   Description:  Pending SHUB 2 EXT IO INT3                           */
+#define SH2_EVENT_OCCURRED_EXTIO_INT3_SHFT       34
+#define SH2_EVENT_OCCURRED_EXTIO_INT3_MASK       0x0000000400000000
+
+#define SH_ALL_INT_MASK \
+       (SH_EVENT_OCCURRED_UART_INT_MASK | SH_EVENT_OCCURRED_IPI_INT_MASK | \
+        SH_EVENT_OCCURRED_II_INT0_MASK | SH_EVENT_OCCURRED_II_INT1_MASK | \
+        SH_EVENT_OCCURRED_II_INT1_MASK | SH2_EVENT_OCCURRED_EXTIO_INT2_MASK | \
+        SH2_EVENT_OCCURRED_EXTIO_INT3_MASK)
+
+
 /* ==================================================================== */
 /*                         LEDS                                         */
 /* ==================================================================== */