]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] alpha pt_regs cleanups: handle_irq()
authorAl Viro <viro@ftp.linux.org.uk>
Sun, 8 Oct 2006 13:37:32 +0000 (14:37 +0100)
committerLinus Torvalds <torvalds@g5.osdl.org>
Sun, 8 Oct 2006 19:32:35 +0000 (12:32 -0700)
isa_no_iack_sc_device_interrupt() always gets get_irq_regs() as
argument; kill that argument.

All but two callers of handle_irq() pass get_irq_regs() as argument;
convert the remaining two, kill set_irq_regs() inside handle_irq().

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
22 files changed:
arch/alpha/kernel/irq.c
arch/alpha/kernel/irq_alpha.c
arch/alpha/kernel/irq_i8259.c
arch/alpha/kernel/irq_impl.h
arch/alpha/kernel/irq_pyxis.c
arch/alpha/kernel/irq_srm.c
arch/alpha/kernel/sys_alcor.c
arch/alpha/kernel/sys_cabriolet.c
arch/alpha/kernel/sys_dp264.c
arch/alpha/kernel/sys_eb64p.c
arch/alpha/kernel/sys_eiger.c
arch/alpha/kernel/sys_jensen.c
arch/alpha/kernel/sys_marvel.c
arch/alpha/kernel/sys_miata.c
arch/alpha/kernel/sys_mikasa.c
arch/alpha/kernel/sys_noritake.c
arch/alpha/kernel/sys_rawhide.c
arch/alpha/kernel/sys_rx164.c
arch/alpha/kernel/sys_sable.c
arch/alpha/kernel/sys_takara.c
arch/alpha/kernel/sys_titan.c
arch/alpha/kernel/sys_wildfire.c

index dba4e70926f55041915ec6d9794655c1a6618564..facf82a5499a84ce83e72e4d4a70324d0ea224d5 100644 (file)
@@ -127,9 +127,8 @@ unlock:
 #define MAX_ILLEGAL_IRQS 16
 
 void
-handle_irq(int irq, struct pt_regs * regs)
+handle_irq(int irq)
 {      
-       struct pt_regs *old_regs;
        /* 
         * We ack quickly, we don't want the irq controller
         * thinking we're snobs just because some other CPU has
@@ -150,7 +149,6 @@ handle_irq(int irq, struct pt_regs * regs)
                return;
        }
 
-       old_regs = set_irq_regs(regs);
        irq_enter();
        /*
         * __do_IRQ() must be called with IPL_MAX. Note that we do not
@@ -161,5 +159,4 @@ handle_irq(int irq, struct pt_regs * regs)
        local_irq_disable();
        __do_IRQ(irq);
        irq_exit();
-       set_irq_regs(old_regs);
 }
index d14cc423aa482bf5b40b62a7d2c4dfcb33fb1034..51d66b7f99e3a9b67975306593cd159ba682a014 100644 (file)
@@ -52,6 +52,7 @@ do_entInt(unsigned long type, unsigned long vector,
 #endif
                break;
        case 1:
+               old_regs = set_irq_regs(regs);
 #ifdef CONFIG_SMP
          {
                long cpu;
@@ -62,12 +63,13 @@ do_entInt(unsigned long type, unsigned long vector,
                if (cpu != boot_cpuid) {
                        kstat_cpu(cpu).irqs[RTC_IRQ]++;
                } else {
-                       handle_irq(RTC_IRQ, regs);
+                       handle_irq(RTC_IRQ);
                }
          }
 #else
-               handle_irq(RTC_IRQ, regs);
+               handle_irq(RTC_IRQ);
 #endif
+               set_irq_regs(old_regs);
                return;
        case 2:
                alpha_mv.machine_check(vector, la_ptr, regs);
index 6c70f8b97b72fc7a33fb45a1edff02efa1ec2ede..9405bee9894e9c4febd62efb2e2487dc63e5bf13 100644 (file)
@@ -147,13 +147,13 @@ isa_device_interrupt(unsigned long vector)
         */
        int j = *(vuip) IACK_SC;
        j &= 0xff;
-       handle_irq(j, get_irq_regs());
+       handle_irq(j);
 }
 #endif
 
 #if defined(CONFIG_ALPHA_GENERIC) || !defined(IACK_SC)
 void
-isa_no_iack_sc_device_interrupt(unsigned long vector, struct pt_regs *regs)
+isa_no_iack_sc_device_interrupt(unsigned long vector)
 {
        unsigned long pic;
 
@@ -176,7 +176,7 @@ isa_no_iack_sc_device_interrupt(unsigned long vector, struct pt_regs *regs)
        while (pic) {
                int j = ffz(~pic);
                pic &= pic - 1;
-               handle_irq(j, regs);
+               handle_irq(j);
        }
 }
 #endif
index 5d84dbdcdb89581e61ec99d9816e4bde99425306..cc9a8a7aa279e05b5a16876f52f563467611eb2f 100644 (file)
@@ -16,7 +16,7 @@
 #define RTC_IRQ    8
 
 extern void isa_device_interrupt(unsigned long);
-extern void isa_no_iack_sc_device_interrupt(unsigned long, struct pt_regs *);
+extern void isa_no_iack_sc_device_interrupt(unsigned long);
 extern void srm_device_interrupt(unsigned long);
 extern void pyxis_device_interrupt(unsigned long);
 
@@ -39,4 +39,4 @@ extern void i8259a_end_irq(unsigned int);
 extern struct hw_interrupt_type i8259a_irq_type;
 extern void init_i8259a_irqs(void);
 
-extern void handle_irq(int irq, struct pt_regs * regs);
+extern void handle_irq(int irq);
index 686dc22111b2da9dd8b57c454b06fa04b2be9a06..d53edbccbfe5d88653c59433be2d29147800c33f 100644 (file)
@@ -100,7 +100,7 @@ pyxis_device_interrupt(unsigned long vector)
                if (i == 7)
                        isa_device_interrupt(vector);
                else
-                       handle_irq(16+i, get_irq_regs());
+                       handle_irq(16+i);
        }
 }
 
index 2e9f6d421a8e2a788e716ecacb4decb286fb272d..32212014fbe91632e9bb80b5307725d16e758d1a 100644 (file)
@@ -75,5 +75,5 @@ void
 srm_device_interrupt(unsigned long vector)
 {
        int irq = (vector - 0x800) >> 4;
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
index 2d412c8765499ed7572f476992bc8208bfaa4d51..49bedfbbd31bedc7986f31b6182356d8d2690959 100644 (file)
@@ -118,7 +118,7 @@ alcor_device_interrupt(unsigned long vector)
                if (i == 31) {
                        isa_device_interrupt(vector);
                } else {
-                       handle_irq(16 + i, get_irq_regs());
+                       handle_irq(16 + i);
                }
        }
 }
index e75f0cea6fccd5d2110f00d8ccfaf01558e63ac7..ace475c124f69d9d2e248268e8ef3436c4262f1e 100644 (file)
@@ -100,7 +100,7 @@ cabriolet_device_interrupt(unsigned long v)
                if (i == 4) {
                        isa_device_interrupt(v);
                } else {
-                       handle_irq(16 + i, get_irq_regs());
+                       handle_irq(16 + i);
                }
        }
 }
index 57dce0098a1bf63342c8c04ca92afc856de9ebb7..85d2f933dd07b0b8d9ca88f13646e302d13e1328 100644 (file)
@@ -238,7 +238,7 @@ dp264_device_interrupt(unsigned long vector)
                if (i == 55)
                        isa_device_interrupt(vector);
                else
-                       handle_irq(16 + i, get_irq_regs());
+                       handle_irq(16 + i);
 #if 0
                TSUNAMI_cchip->dir0.csr = 1UL << i; mb();
                tmp = TSUNAMI_cchip->dir0.csr;
@@ -268,7 +268,7 @@ dp264_srm_device_interrupt(unsigned long vector)
        if (irq >= 32)
                irq -= 16;
 
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void 
@@ -290,7 +290,7 @@ clipper_srm_device_interrupt(unsigned long vector)
         *
         * Eg IRQ 24 is DRIR bit 8, etc, etc
         */
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index 90d27256d7d616d2777d3622ab0d715c4cd7f68d..9c5a306dc0ee825a47d3d8c0bd27e2d091069086 100644 (file)
@@ -99,7 +99,7 @@ eb64p_device_interrupt(unsigned long vector)
                if (i == 5) {
                        isa_device_interrupt(vector);
                } else {
-                       handle_irq(16 + i, get_irq_regs());
+                       handle_irq(16 + i);
                }
        }
 }
index f38cded2df97ff9b7ff9a0e29fefe9e7b9ebe03e..7ef3b6fb3700c877309e3100c0d9991de7659b44 100644 (file)
@@ -118,10 +118,10 @@ eiger_device_interrupt(unsigned long vector)
                 * despatch an interrupt if it's set.
                 */
 
-               if (intstatus & 8) handle_irq(16+3, get_irq_regs());
-               if (intstatus & 4) handle_irq(16+2, get_irq_regs());
-               if (intstatus & 2) handle_irq(16+1, get_irq_regs());
-               if (intstatus & 1) handle_irq(16+0, get_irq_regs());
+               if (intstatus & 8) handle_irq(16+3);
+               if (intstatus & 4) handle_irq(16+2);
+               if (intstatus & 2) handle_irq(16+1);
+               if (intstatus & 1) handle_irq(16+0);
        } else {
                isa_device_interrupt(vector);
        }
@@ -131,7 +131,7 @@ static void
 eiger_srm_device_interrupt(unsigned long vector)
 {
        int irq = (vector - 0x800) >> 4;
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index fc316369f4d4f3ed5d0a5a2fcf1c9fe42637b45e..a7b89022938e7bc42f8da2ecb965bc101714d2cb 100644 (file)
@@ -198,7 +198,7 @@ jensen_device_interrupt(unsigned long vector)
         }
 #endif
 
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index 4ea5615be43aa7efe0ab0894cb00a73febe88fba..e349f03b830e9c96826646877006e640dcf0edad 100644 (file)
@@ -64,7 +64,7 @@ io7_device_interrupt(unsigned long vector)
        irq &= MARVEL_IRQ_VEC_IRQ_MASK;         /* not too many bits */
        irq |= pid << MARVEL_IRQ_VEC_PE_SHIFT;  /* merge the pid     */
 
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static volatile unsigned long *
index fbbd95212a96065373e23a483dd3bfe2f42c7206..b8b817feb1eedb8db7be5baa8df5639cb02a4b0f 100644 (file)
@@ -56,7 +56,7 @@ miata_srm_device_interrupt(unsigned long vector)
        if (irq >= 16)
                irq = irq + 8;
 
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index 5429ba0e08f120d54323b7d58f54689ef1f06d4e..ba98048d61a8312b6c3e9cc1170bf2ebbcd3452c 100644 (file)
@@ -99,7 +99,7 @@ mikasa_device_interrupt(unsigned long vector)
                if (i < 16) {
                        isa_device_interrupt(vector);
                } else {
-                       handle_irq(i, get_irq_regs());
+                       handle_irq(i);
                }
        }
 }
index b9a843447b8999326c7b7f649c01e0ada811180f..679836205f0422ba97fecd19dcbf3fd709daf178 100644 (file)
@@ -98,7 +98,7 @@ noritake_device_interrupt(unsigned long vector)
                if (i < 16) {
                        isa_device_interrupt(vector);
                } else {
-                       handle_irq(i, get_irq_regs());
+                       handle_irq(i);
                }
        }
 }
@@ -122,7 +122,7 @@ noritake_srm_device_interrupt(unsigned long vector)
        if (irq >= 16)
                irq = irq + 1;
 
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index bef65162bfabf4c10ff73b914f280d12033d674a..581d08c70b9234302cb65126756659a2d8b25839 100644 (file)
@@ -158,7 +158,7 @@ rawhide_srm_device_interrupt(unsigned long vector)
        /* Adjust by which hose it is from.  */
        irq -= ((irq + 16) >> 2) & 0x38;
 
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index fa8eef8dd8c6578901f059d113c9958450c568f0..ce1faa6f1df1f4e1aba6ac57f3f8001f75bdf2f4 100644 (file)
@@ -102,9 +102,9 @@ rx164_device_interrupt(unsigned long vector)
                i = ffz(~pld);
                pld &= pld - 1; /* clear least bit set */
                if (i == 20) {
-                       isa_no_iack_sc_device_interrupt(vector, get_irq_regs());
+                       isa_no_iack_sc_device_interrupt(vector);
                } else {
-                       handle_irq(16+i, get_irq_regs());
+                       handle_irq(16+i);
                }
        }
 }
index 791379101e7c1f90f251c13b149d7e6145509196..906019cfa6815ff8d6c00d6a299313090398b7bc 100644 (file)
@@ -526,7 +526,7 @@ sable_lynx_srm_device_interrupt(unsigned long vector)
        printk("%s: vector 0x%lx bit 0x%x irq 0x%x\n",
               __FUNCTION__, vector, bit, irq);
 #endif
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index ce2d3b081dc8e046f0042c2f3f8ebfbf7a9b9e1f..9bd9a31450c64a414ba08cc137ae349a535b0497 100644 (file)
@@ -112,10 +112,10 @@ takara_device_interrupt(unsigned long vector)
                 * despatch an interrupt if it's set.
                 */
 
-               if (intstatus & 8) handle_irq(16+3, get_irq_regs());
-               if (intstatus & 4) handle_irq(16+2, get_irq_regs());
-               if (intstatus & 2) handle_irq(16+1, get_irq_regs());
-               if (intstatus & 1) handle_irq(16+0, get_irq_regs());
+               if (intstatus & 8) handle_irq(16+3);
+               if (intstatus & 4) handle_irq(16+2);
+               if (intstatus & 2) handle_irq(16+1);
+               if (intstatus & 1) handle_irq(16+0);
        } else {
                isa_device_interrupt (vector);
        }
@@ -125,7 +125,7 @@ static void
 takara_srm_device_interrupt(unsigned long vector)
 {
        int irq = (vector - 0x800) >> 4;
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 static void __init
index 1473aa0e69826ef4e446d2c57d0d12be0c8a87ed..e8e8ec9c0f4e2cff6f1690335c2ab9c3794a20ac 100644 (file)
@@ -178,7 +178,7 @@ titan_srm_device_interrupt(unsigned long vector)
        int irq;
 
        irq = (vector - 0x800) >> 4;
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
 }
 
 
index ddf5edd0cecd5e14102e3f18a67bce10c48a2da3..42c3eede4d099a3a970f9d78e25f42f3f8eeb8b1 100644 (file)
@@ -246,7 +246,7 @@ wildfire_device_interrupt(unsigned long vector)
         * bits 5-0:    irq in PCA
         */
 
-       handle_irq(irq, get_irq_regs());
+       handle_irq(irq);
        return;
 }