diff options
author | David S. Miller <davem@sunset.davemloft.net> | 2007-10-14 02:52:14 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-10-14 02:52:14 -0400 |
commit | 45b3f4cc6025bdb14beb65b8a3a732bf55d1bc41 (patch) | |
tree | c388e714dcd353c9736c2e3a38bfa1e7300f62e9 /arch | |
parent | 256c1df36bbec6530c6f9b5a840cc5e87315c19e (diff) |
[SPARC64]: virt_to_real_irq_table --> virt_irq_table
It no longer translates to "real irqs" (aka. INO buckets)
so reflect that by using a simpler name for it.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/sparc64/kernel/irq.c | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/arch/sparc64/kernel/irq.c b/arch/sparc64/kernel/irq.c index 695b9e40cd80..f3922e5a89f6 100644 --- a/arch/sparc64/kernel/irq.c +++ b/arch/sparc64/kernel/irq.c | |||
@@ -128,7 +128,7 @@ static struct { | |||
128 | unsigned int dev_handle; | 128 | unsigned int dev_handle; |
129 | unsigned int dev_ino; | 129 | unsigned int dev_ino; |
130 | unsigned int in_use; | 130 | unsigned int in_use; |
131 | } virt_to_real_irq_table[NR_IRQS]; | 131 | } virt_irq_table[NR_IRQS]; |
132 | static DEFINE_SPINLOCK(virt_irq_alloc_lock); | 132 | static DEFINE_SPINLOCK(virt_irq_alloc_lock); |
133 | 133 | ||
134 | unsigned char virt_irq_alloc(unsigned int dev_handle, | 134 | unsigned char virt_irq_alloc(unsigned int dev_handle, |
@@ -142,16 +142,16 @@ unsigned char virt_irq_alloc(unsigned int dev_handle, | |||
142 | spin_lock_irqsave(&virt_irq_alloc_lock, flags); | 142 | spin_lock_irqsave(&virt_irq_alloc_lock, flags); |
143 | 143 | ||
144 | for (ent = 1; ent < NR_IRQS; ent++) { | 144 | for (ent = 1; ent < NR_IRQS; ent++) { |
145 | if (!virt_to_real_irq_table[ent].in_use) | 145 | if (!virt_irq_table[ent].in_use) |
146 | break; | 146 | break; |
147 | } | 147 | } |
148 | if (ent >= NR_IRQS) { | 148 | if (ent >= NR_IRQS) { |
149 | printk(KERN_ERR "IRQ: Out of virtual IRQs.\n"); | 149 | printk(KERN_ERR "IRQ: Out of virtual IRQs.\n"); |
150 | ent = 0; | 150 | ent = 0; |
151 | } else { | 151 | } else { |
152 | virt_to_real_irq_table[ent].dev_handle = dev_handle; | 152 | virt_irq_table[ent].dev_handle = dev_handle; |
153 | virt_to_real_irq_table[ent].dev_ino = dev_ino; | 153 | virt_irq_table[ent].dev_ino = dev_ino; |
154 | virt_to_real_irq_table[ent].in_use = 1; | 154 | virt_irq_table[ent].in_use = 1; |
155 | } | 155 | } |
156 | 156 | ||
157 | spin_unlock_irqrestore(&virt_irq_alloc_lock, flags); | 157 | spin_unlock_irqrestore(&virt_irq_alloc_lock, flags); |
@@ -169,7 +169,7 @@ void virt_irq_free(unsigned int virt_irq) | |||
169 | 169 | ||
170 | spin_lock_irqsave(&virt_irq_alloc_lock, flags); | 170 | spin_lock_irqsave(&virt_irq_alloc_lock, flags); |
171 | 171 | ||
172 | virt_to_real_irq_table[virt_irq].in_use = 0; | 172 | virt_irq_table[virt_irq].in_use = 0; |
173 | 173 | ||
174 | spin_unlock_irqrestore(&virt_irq_alloc_lock, flags); | 174 | spin_unlock_irqrestore(&virt_irq_alloc_lock, flags); |
175 | } | 175 | } |
@@ -360,7 +360,7 @@ static void sun4u_irq_end(unsigned int virt_irq) | |||
360 | 360 | ||
361 | static void sun4v_irq_enable(unsigned int virt_irq) | 361 | static void sun4v_irq_enable(unsigned int virt_irq) |
362 | { | 362 | { |
363 | unsigned int ino = virt_to_real_irq_table[virt_irq].dev_ino; | 363 | unsigned int ino = virt_irq_table[virt_irq].dev_ino; |
364 | unsigned long cpuid = irq_choose_cpu(virt_irq); | 364 | unsigned long cpuid = irq_choose_cpu(virt_irq); |
365 | int err; | 365 | int err; |
366 | 366 | ||
@@ -380,7 +380,7 @@ static void sun4v_irq_enable(unsigned int virt_irq) | |||
380 | 380 | ||
381 | static void sun4v_set_affinity(unsigned int virt_irq, cpumask_t mask) | 381 | static void sun4v_set_affinity(unsigned int virt_irq, cpumask_t mask) |
382 | { | 382 | { |
383 | unsigned int ino = virt_to_real_irq_table[virt_irq].dev_ino; | 383 | unsigned int ino = virt_irq_table[virt_irq].dev_ino; |
384 | unsigned long cpuid = irq_choose_cpu(virt_irq); | 384 | unsigned long cpuid = irq_choose_cpu(virt_irq); |
385 | int err; | 385 | int err; |
386 | 386 | ||
@@ -392,7 +392,7 @@ static void sun4v_set_affinity(unsigned int virt_irq, cpumask_t mask) | |||
392 | 392 | ||
393 | static void sun4v_irq_disable(unsigned int virt_irq) | 393 | static void sun4v_irq_disable(unsigned int virt_irq) |
394 | { | 394 | { |
395 | unsigned int ino = virt_to_real_irq_table[virt_irq].dev_ino; | 395 | unsigned int ino = virt_irq_table[virt_irq].dev_ino; |
396 | int err; | 396 | int err; |
397 | 397 | ||
398 | err = sun4v_intr_setenabled(ino, HV_INTR_DISABLED); | 398 | err = sun4v_intr_setenabled(ino, HV_INTR_DISABLED); |
@@ -403,7 +403,7 @@ static void sun4v_irq_disable(unsigned int virt_irq) | |||
403 | 403 | ||
404 | static void sun4v_irq_end(unsigned int virt_irq) | 404 | static void sun4v_irq_end(unsigned int virt_irq) |
405 | { | 405 | { |
406 | unsigned int ino = virt_to_real_irq_table[virt_irq].dev_ino; | 406 | unsigned int ino = virt_irq_table[virt_irq].dev_ino; |
407 | struct irq_desc *desc = irq_desc + virt_irq; | 407 | struct irq_desc *desc = irq_desc + virt_irq; |
408 | int err; | 408 | int err; |
409 | 409 | ||
@@ -423,8 +423,8 @@ static void sun4v_virq_enable(unsigned int virt_irq) | |||
423 | 423 | ||
424 | cpuid = irq_choose_cpu(virt_irq); | 424 | cpuid = irq_choose_cpu(virt_irq); |
425 | 425 | ||
426 | dev_handle = virt_to_real_irq_table[virt_irq].dev_handle; | 426 | dev_handle = virt_irq_table[virt_irq].dev_handle; |
427 | dev_ino = virt_to_real_irq_table[virt_irq].dev_ino; | 427 | dev_ino = virt_irq_table[virt_irq].dev_ino; |
428 | 428 | ||
429 | err = sun4v_vintr_set_target(dev_handle, dev_ino, cpuid); | 429 | err = sun4v_vintr_set_target(dev_handle, dev_ino, cpuid); |
430 | if (err != HV_EOK) | 430 | if (err != HV_EOK) |
@@ -452,8 +452,8 @@ static void sun4v_virt_set_affinity(unsigned int virt_irq, cpumask_t mask) | |||
452 | 452 | ||
453 | cpuid = irq_choose_cpu(virt_irq); | 453 | cpuid = irq_choose_cpu(virt_irq); |
454 | 454 | ||
455 | dev_handle = virt_to_real_irq_table[virt_irq].dev_handle; | 455 | dev_handle = virt_irq_table[virt_irq].dev_handle; |
456 | dev_ino = virt_to_real_irq_table[virt_irq].dev_ino; | 456 | dev_ino = virt_irq_table[virt_irq].dev_ino; |
457 | 457 | ||
458 | err = sun4v_vintr_set_target(dev_handle, dev_ino, cpuid); | 458 | err = sun4v_vintr_set_target(dev_handle, dev_ino, cpuid); |
459 | if (err != HV_EOK) | 459 | if (err != HV_EOK) |
@@ -467,8 +467,8 @@ static void sun4v_virq_disable(unsigned int virt_irq) | |||
467 | unsigned long dev_handle, dev_ino; | 467 | unsigned long dev_handle, dev_ino; |
468 | int err; | 468 | int err; |
469 | 469 | ||
470 | dev_handle = virt_to_real_irq_table[virt_irq].dev_handle; | 470 | dev_handle = virt_irq_table[virt_irq].dev_handle; |
471 | dev_ino = virt_to_real_irq_table[virt_irq].dev_ino; | 471 | dev_ino = virt_irq_table[virt_irq].dev_ino; |
472 | 472 | ||
473 | err = sun4v_vintr_set_valid(dev_handle, dev_ino, | 473 | err = sun4v_vintr_set_valid(dev_handle, dev_ino, |
474 | HV_INTR_DISABLED); | 474 | HV_INTR_DISABLED); |
@@ -487,8 +487,8 @@ static void sun4v_virq_end(unsigned int virt_irq) | |||
487 | if (unlikely(desc->status & (IRQ_DISABLED|IRQ_INPROGRESS))) | 487 | if (unlikely(desc->status & (IRQ_DISABLED|IRQ_INPROGRESS))) |
488 | return; | 488 | return; |
489 | 489 | ||
490 | dev_handle = virt_to_real_irq_table[virt_irq].dev_handle; | 490 | dev_handle = virt_irq_table[virt_irq].dev_handle; |
491 | dev_ino = virt_to_real_irq_table[virt_irq].dev_ino; | 491 | dev_ino = virt_irq_table[virt_irq].dev_ino; |
492 | 492 | ||
493 | err = sun4v_vintr_set_state(dev_handle, dev_ino, | 493 | err = sun4v_vintr_set_state(dev_handle, dev_ino, |
494 | HV_INTR_STATE_IDLE); | 494 | HV_INTR_STATE_IDLE); |
@@ -503,7 +503,7 @@ static void run_pre_handler(unsigned int virt_irq) | |||
503 | struct irq_handler_data *data = get_irq_chip_data(virt_irq); | 503 | struct irq_handler_data *data = get_irq_chip_data(virt_irq); |
504 | unsigned int ino; | 504 | unsigned int ino; |
505 | 505 | ||
506 | ino = virt_to_real_irq_table[virt_irq].dev_ino; | 506 | ino = virt_irq_table[virt_irq].dev_ino; |
507 | if (likely(data->pre_handler)) { | 507 | if (likely(data->pre_handler)) { |
508 | data->pre_handler(ino, | 508 | data->pre_handler(ino, |
509 | data->pre_handler_arg1, | 509 | data->pre_handler_arg1, |
@@ -693,7 +693,7 @@ unsigned int sun4v_build_virq(u32 devhandle, unsigned int devino) | |||
693 | 693 | ||
694 | void ack_bad_irq(unsigned int virt_irq) | 694 | void ack_bad_irq(unsigned int virt_irq) |
695 | { | 695 | { |
696 | unsigned int ino = virt_to_real_irq_table[virt_irq].dev_ino; | 696 | unsigned int ino = virt_irq_table[virt_irq].dev_ino; |
697 | 697 | ||
698 | if (!ino) | 698 | if (!ino) |
699 | ino = 0xdeadbeef; | 699 | ino = 0xdeadbeef; |