Re: [PATCH] mips irq cleanups

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 02 Nov 2006 02:08:36 +0900 (JST), Atsushi Nemoto <anemo@xxxxxxxxxxxxx> wrote:
> This is a big irq cleanup patch.
> 
> * Use set_irq_chip() to register irq_chip.
> * Initialize .mask, .unmask, .mask_ack field.  Functions for these
>   method are already exist in most case.
> * Do not initialize .startup, .shutdown, .enable, .disable fields if
>   default routines provided by irq_chip_set_defaults() were suitable.
> * Remove redundant irq_desc initializations.
> * Remove unnecessary local_irq_save/local_irq_restore, spin_lock.

I missed some cleanups in irq_cpu.c.  Here is a patch against the
patch.  I can send revised whole patch if you want.


Subject: [PATCH] mips irq cleanups (missing bits in irq_cpu.c)

remove unneeded mips_cpu_irq_ack and initialize .mask_ack of
mips_cpu_irq_controller and mips_mt_cpu_irq_controller.

Signed-off-by: Atsushi Nemoto <anemo@xxxxxxxxxxxxx>

diff --git a/arch/mips/kernel/irq_cpu.c b/arch/mips/kernel/irq_cpu.c
index 79fea0f..3b7cfa4 100644
--- a/arch/mips/kernel/irq_cpu.c
+++ b/arch/mips/kernel/irq_cpu.c
@@ -50,15 +50,6 @@ static inline void mask_mips_irq(unsigne
 	irq_disable_hazard();
 }
 
-/*
- * While we ack the interrupt interrupts are disabled and thus we don't need
- * to deal with concurrency issues.  Same for mips_cpu_irq_end.
- */
-static void mips_cpu_irq_ack(unsigned int irq)
-{
-	mask_mips_irq(irq);
-}
-
 static void mips_cpu_irq_end(unsigned int irq)
 {
 	if (!(irq_desc[irq].status & (IRQ_DISABLED | IRQ_INPROGRESS)))
@@ -67,8 +58,9 @@ static void mips_cpu_irq_end(unsigned in
 
 static struct irq_chip mips_cpu_irq_controller = {
 	.typename	= "MIPS",
-	.ack		= mips_cpu_irq_ack,
+	.ack		= mask_mips_irq,
 	.mask		= mask_mips_irq,
+	.mask_ack	= mask_mips_irq,
 	.unmask		= unmask_mips_irq,
 	.end		= mips_cpu_irq_end,
 };
@@ -110,6 +102,7 @@ static struct irq_chip mips_mt_cpu_irq_c
 	.startup	= mips_mt_cpu_irq_startup,
 	.ack		= mips_mt_cpu_irq_ack,
 	.mask		= mask_mips_mt_irq,
+	.mask_ack	= mips_mt_cpu_irq_ack,
 	.unmask		= unmask_mips_mt_irq,
 	.end		= mips_mt_cpu_irq_end,
 };


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux