Commit 4bf447d6 authored by David S. Miller's avatar David S. Miller

[SPARC64]: Pass correct ino to sun4v_intr_*().

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent a615fea4
...@@ -152,10 +152,11 @@ void enable_irq(unsigned int irq) ...@@ -152,10 +152,11 @@ void enable_irq(unsigned int irq)
preempt_disable(); preempt_disable();
if (tlb_type == hypervisor) { if (tlb_type == hypervisor) {
unsigned int ino = __irq_ino(irq);
int cpu = hard_smp_processor_id(); int cpu = hard_smp_processor_id();
sun4v_intr_settarget(irq, cpu); sun4v_intr_settarget(ino, cpu);
sun4v_intr_setenabled(irq, HV_INTR_ENABLED); sun4v_intr_setenabled(ino, HV_INTR_ENABLED);
} else { } else {
if (tlb_type == cheetah || tlb_type == cheetah_plus) { if (tlb_type == cheetah || tlb_type == cheetah_plus) {
unsigned long ver; unsigned long ver;
...@@ -214,7 +215,9 @@ void disable_irq(unsigned int irq) ...@@ -214,7 +215,9 @@ void disable_irq(unsigned int irq)
imap = bucket->imap; imap = bucket->imap;
if (imap != 0UL) { if (imap != 0UL) {
if (tlb_type == hypervisor) { if (tlb_type == hypervisor) {
sun4v_intr_setenabled(irq, HV_INTR_DISABLED); unsigned int ino = __irq_ino(irq);
sun4v_intr_setenabled(ino, HV_INTR_DISABLED);
} else { } else {
u32 tmp; u32 tmp;
...@@ -643,9 +646,9 @@ static void process_bucket(int irq, struct ino_bucket *bp, struct pt_regs *regs) ...@@ -643,9 +646,9 @@ static void process_bucket(int irq, struct ino_bucket *bp, struct pt_regs *regs)
} }
if (bp->pil != 0) { if (bp->pil != 0) {
if (tlb_type == hypervisor) { if (tlb_type == hypervisor) {
unsigned int irq = __irq(bp); unsigned int ino = __irq_ino(bp);
sun4v_intr_setstate(irq, HV_INTR_STATE_IDLE); sun4v_intr_setstate(ino, HV_INTR_STATE_IDLE);
} else { } else {
upa_writel(ICLR_IDLE, bp->iclr); upa_writel(ICLR_IDLE, bp->iclr);
/* Test and add entropy */ /* Test and add entropy */
...@@ -791,10 +794,10 @@ static int retarget_one_irq(struct irqaction *p, int goal_cpu) ...@@ -791,10 +794,10 @@ static int retarget_one_irq(struct irqaction *p, int goal_cpu)
} }
if (tlb_type == hypervisor) { if (tlb_type == hypervisor) {
unsigned int irq = __irq(bucket); unsigned int ino = __irq_ino(bucket);
sun4v_intr_settarget(irq, goal_cpu); sun4v_intr_settarget(ino, goal_cpu);
sun4v_intr_setenabled(irq, HV_INTR_ENABLED); sun4v_intr_setenabled(ino, HV_INTR_ENABLED);
} else { } else {
unsigned int tid; unsigned int tid;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment