MIPS: SGI-IP27: rework HUB interrupts
This commit rearranges the HUB interrupt code by using MIPS_IRQ_CPU interrupt handling code and modern Linux IRQ framework features to get rid of global arrays. It also adds support for irq affinity setting. Signed-off-by: Thomas Bogendoerfer <tbogendoerfer@suse.de> Signed-off-by: Paul Burton <paul.burton@mips.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: James Hogan <jhogan@kernel.org> Cc: linux-mips@vger.kernel.org Cc: linux-kernel@vger.kernel.org
This commit is contained in:

committed by
Paul Burton

parent
2c86562047
commit
69a07a41d9
@@ -10,13 +10,15 @@
|
||||
#ifndef __ASM_MACH_IP27_IRQ_H
|
||||
#define __ASM_MACH_IP27_IRQ_H
|
||||
|
||||
/*
|
||||
* A hardwired interrupt number is completely stupid for this system - a
|
||||
* large configuration might have thousands if not tenthousands of
|
||||
* interrupts.
|
||||
*/
|
||||
#define NR_IRQS 256
|
||||
|
||||
#include_next <irq.h>
|
||||
|
||||
#define IP27_HUB_PEND0_IRQ (MIPS_CPU_IRQ_BASE + 2)
|
||||
#define IP27_HUB_PEND1_IRQ (MIPS_CPU_IRQ_BASE + 3)
|
||||
#define IP27_RT_TIMER_IRQ (MIPS_CPU_IRQ_BASE + 4)
|
||||
|
||||
#define IP27_HUB_IRQ_BASE (MIPS_CPU_IRQ_BASE + 8)
|
||||
#define IP27_HUB_IRQ_COUNT 128
|
||||
|
||||
#endif /* __ASM_MACH_IP27_IRQ_H */
|
||||
|
@@ -8,20 +8,11 @@
|
||||
|
||||
#define pa_to_nid(addr) NASID_TO_COMPACT_NODEID(NASID_GET(addr))
|
||||
|
||||
#define LEVELS_PER_SLICE 128
|
||||
|
||||
struct slice_data {
|
||||
unsigned long irq_enable_mask[2];
|
||||
int level_to_irq[LEVELS_PER_SLICE];
|
||||
};
|
||||
|
||||
struct hub_data {
|
||||
kern_vars_t kern_vars;
|
||||
DECLARE_BITMAP(h_bigwin_used, HUB_NUM_BIG_WINDOW);
|
||||
cpumask_t h_cpus;
|
||||
unsigned long slice_map;
|
||||
unsigned long irq_alloc_mask[2];
|
||||
struct slice_data slice[2];
|
||||
};
|
||||
|
||||
struct node_data {
|
||||
|
@@ -808,7 +808,6 @@ struct bridge_controller {
|
||||
struct bridge_regs *base;
|
||||
nasid_t nasid;
|
||||
unsigned int widget_id;
|
||||
unsigned int irq_cpu;
|
||||
u64 baddr;
|
||||
unsigned int pci_int[8];
|
||||
};
|
||||
@@ -823,8 +822,7 @@ struct bridge_controller {
|
||||
#define bridge_clr(bc, reg, val) \
|
||||
__raw_writel(__raw_readl(&bc->base->reg) & ~(val), &bc->base->reg)
|
||||
|
||||
extern void register_bridge_irq(unsigned int irq);
|
||||
extern int request_bridge_irq(struct bridge_controller *bc);
|
||||
extern int request_bridge_irq(struct bridge_controller *bc, int pin);
|
||||
|
||||
extern struct pci_ops bridge_pci_ops;
|
||||
|
||||
|
Reference in New Issue
Block a user