clean include/asm-sparc/irq.h
PATCH 1/3 clean include/asm-sparc/irq.h
Move stuff used only by arch/sparc/kernel/* into arch/sparc/kernel/irq.h and into individual files in there (e.g. macros internal to sun4m_irq.c, etc.)
Signed-off-by Al Viro <[email protected]>
--- arch/sparc/kernel/irq.c | 2 + arch/sparc/kernel/irq.h | 48 ++++++++++++++ arch/sparc/kernel/pcic.c | 1 + arch/sparc/kernel/smp.c | 2 + arch/sparc/kernel/sun4c_irq.c | 15 +++++ arch/sparc/kernel/sun4d_irq.c | 2 + arch/sparc/kernel/sun4d_smp.c | 1 + arch/sparc/kernel/sun4m_irq.c | 74 ++++++++++++++++++++++ arch/sparc/kernel/sun4m_smp.c | 2 + arch/sparc/kernel/tick14.c | 2 + arch/sparc/kernel/time.c | 2 + include/asm-sparc/irq.h | 136 ----------------------------------------- 12 files changed, 151 insertions(+), 136 deletions(-) create mode 100644 arch/sparc/kernel/irq.h
arch/sparc/kernel/irq.c +2 -0
@@ -47,6 +47,8 @@#include <asm/cacheflush.h> #include <asm/irq_regs.h> +#include "irq.h" +#ifdef CONFIG_SMP #define SMP_NOP2 "nop; nop;\n\t"#define SMP_NOP3 "nop; nop; nop;\n\t"
arch/sparc/kernel/irq.h new file +48 -0
48 lines not on this page · raw message
arch/sparc/kernel/pcic.c +1 -0
@@ -36,6 +36,7 @@#include <asm/uaccess.h> #include <asm/irq_regs.h> +#include "irq.h" /* * I studied different documents and many live PROMs both from 2.30
arch/sparc/kernel/smp.c +2 -0
@@ -33,6 +33,8 @@#include <asm/tlbflush.h> #include <asm/cpudata.h> +#include "irq.h" +int smp_num_cpus =1 ;volatile unsigned long cpu_callin_map[NR_CPUS ]__initdata = {0 ,};unsigned char boot_cpu_id =0 ;
arch/sparc/kernel/sun4c_irq.c +15 -0
@@ -18,6 +18,7 @@#include <linux/interrupt.h> #include <linux/slab.h> #include <linux/init.h> +#include "irq.h" #include <asm/ptrace.h> #include <asm/processor.h>
@@ -40,6 +41,20 @@ static struct resource sun4c_timer_eb = { "sun4c_timer" };static struct resource sun4c_intr_eb = {"sun4c_intr" };#endif +/* +* Bit field defines for the interrupt registers on various +* Sparc machines. +*/ + +/* The sun4c interrupt register. */ +#define SUN4C_INT_ENABLE 0x01/* Allow interrupts. */ +#define SUN4C_INT_E14 0x80/* Enable level 14 IRQ. */ +#define SUN4C_INT_E10 0x20/* Enable level 10 IRQ. */ +#define SUN4C_INT_E8 0x10/* Enable level 8 IRQ. */ +#define SUN4C_INT_E6 0x08/* Enable level 6 IRQ. */ +#define SUN4C_INT_E4 0x04/* Enable level 4 IRQ. */ +#define SUN4C_INT_E1 0x02/* Enable level 1 IRQ. */ +/* Pointer to the interrupt enable byte * * Dave Redman ([email protected])
arch/sparc/kernel/sun4d_irq.c +2 -0
@@ -39,6 +39,8 @@#include <asm/cacheflush.h> #include <asm/irq_regs.h> +#include "irq.h" +/* If you trust current SCSI layer to handle different SCSI IRQs, enable this. I don't trust it... -jj */ /* #define DISTRIBUTE_IRQS */
arch/sparc/kernel/sun4d_smp.c +1 -0
@@ -36,6 +36,7 @@#include <asm/cacheflush.h> #include <asm/cpudata.h> +#include "irq.h" #define IRQ_CROSS_CALL 15extern ctxd_t *srmmu_ctx_table_phys;
arch/sparc/kernel/sun4m_irq.c +74 -0
85 lines not on this page · raw message
arch/sparc/kernel/sun4m_smp.c +2 -0
@@ -31,6 +31,8 @@#include <asm/oplib.h> #include <asm/cpudata.h> +#include "irq.h" +#define IRQ_RESCHEDULE 13#define IRQ_STOP_CPU 14#define IRQ_CROSS_CALL 15
arch/sparc/kernel/tick14.c +2 -0
@@ -25,6 +25,8 @@#include <asm/irq.h> #include <asm/io.h> +#include "irq.h" +extern unsigned long lvl14_save[5 ];static unsigned long *linux_lvl14 =NULL ;static unsigned long obp_lvl14[4 ];
arch/sparc/kernel/time.c +2 -0
@@ -44,6 +44,8 @@#include <asm/of_device.h> #include <asm/irq_regs.h> +#include "irq.h" +DEFINE_SPINLOCK (rtc_lock);enum sparc_clock_type sp_clock_typ;DEFINE_SPINLOCK (mostek_lock);
include/asm-sparc/irq.h +0 -136
154 lines not on this page · raw message
Signature · 1 line
1.5.3.GIT
From: Al Viro <[email protected]>
Date: Sat, 21 Jul 2007 23:28:52 +0100
Quoted 6 lines
Move stuff used only by
arch/sparc/kernel/*intoarch/sparc/kernel/irq.hand into individual files in there (e.g. macros internal tosun4m_irq.c, etc.)Signed-off-by Al Viro <[email protected]>
Applied, thanks Al.