diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2011-01-22 06:32:16 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-03-16 21:19:01 -0400 |
commit | cae78728003e41e9346b92f9a1cc5ca3c3e5e70e (patch) | |
tree | 8c477b445e116cef9df90b8129d465a6c2f7d783 /arch/sparc | |
parent | d4d1ec48c4b1568338931bf8e7833543b78ec9d5 (diff) |
sparc64: all pointers to irq_handler_data renamed to handler_data
In preparation of moving to use irq_data.handler_data rename
all pointers to irq_handler_data "handler_data".
This will also prevent name clash when we introduce the
new irq methods.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc')
-rw-r--r-- | arch/sparc/kernel/irq_64.c | 78 |
1 files changed, 39 insertions, 39 deletions
diff --git a/arch/sparc/kernel/irq_64.c b/arch/sparc/kernel/irq_64.c index d4d1233d4ec4..a763f9a6358e 100644 --- a/arch/sparc/kernel/irq_64.c +++ b/arch/sparc/kernel/irq_64.c | |||
@@ -277,15 +277,15 @@ static int irq_choose_cpu(unsigned int virt_irq, const struct cpumask *affinity) | |||
277 | 277 | ||
278 | static void sun4u_irq_enable(unsigned int virt_irq) | 278 | static void sun4u_irq_enable(unsigned int virt_irq) |
279 | { | 279 | { |
280 | struct irq_handler_data *data = get_irq_chip_data(virt_irq); | 280 | struct irq_handler_data *handler_data = get_irq_chip_data(virt_irq); |
281 | 281 | ||
282 | if (likely(data)) { | 282 | if (likely(handler_data)) { |
283 | unsigned long cpuid, imap, val; | 283 | unsigned long cpuid, imap, val; |
284 | unsigned int tid; | 284 | unsigned int tid; |
285 | 285 | ||
286 | cpuid = irq_choose_cpu(virt_irq, | 286 | cpuid = irq_choose_cpu(virt_irq, |
287 | irq_desc[virt_irq].irq_data.affinity); | 287 | irq_desc[virt_irq].irq_data.affinity); |
288 | imap = data->imap; | 288 | imap = handler_data->imap; |
289 | 289 | ||
290 | tid = sun4u_compute_tid(imap, cpuid); | 290 | tid = sun4u_compute_tid(imap, cpuid); |
291 | 291 | ||
@@ -294,21 +294,21 @@ static void sun4u_irq_enable(unsigned int virt_irq) | |||
294 | IMAP_AID_SAFARI | IMAP_NID_SAFARI); | 294 | IMAP_AID_SAFARI | IMAP_NID_SAFARI); |
295 | val |= tid | IMAP_VALID; | 295 | val |= tid | IMAP_VALID; |
296 | upa_writeq(val, imap); | 296 | upa_writeq(val, imap); |
297 | upa_writeq(ICLR_IDLE, data->iclr); | 297 | upa_writeq(ICLR_IDLE, handler_data->iclr); |
298 | } | 298 | } |
299 | } | 299 | } |
300 | 300 | ||
301 | static int sun4u_set_affinity(unsigned int virt_irq, | 301 | static int sun4u_set_affinity(unsigned int virt_irq, |
302 | const struct cpumask *mask) | 302 | const struct cpumask *mask) |
303 | { | 303 | { |
304 | struct irq_handler_data *data = get_irq_chip_data(virt_irq); | 304 | struct irq_handler_data *handler_data = get_irq_chip_data(virt_irq); |
305 | 305 | ||
306 | if (likely(data)) { | 306 | if (likely(handler_data)) { |
307 | unsigned long cpuid, imap, val; | 307 | unsigned long cpuid, imap, val; |
308 | unsigned int tid; | 308 | unsigned int tid; |
309 | 309 | ||
310 | cpuid = irq_choose_cpu(virt_irq, mask); | 310 | cpuid = irq_choose_cpu(virt_irq, mask); |
311 | imap = data->imap; | 311 | imap = handler_data->imap; |
312 | 312 | ||
313 | tid = sun4u_compute_tid(imap, cpuid); | 313 | tid = sun4u_compute_tid(imap, cpuid); |
314 | 314 | ||
@@ -317,7 +317,7 @@ static int sun4u_set_affinity(unsigned int virt_irq, | |||
317 | IMAP_AID_SAFARI | IMAP_NID_SAFARI); | 317 | IMAP_AID_SAFARI | IMAP_NID_SAFARI); |
318 | val |= tid | IMAP_VALID; | 318 | val |= tid | IMAP_VALID; |
319 | upa_writeq(val, imap); | 319 | upa_writeq(val, imap); |
320 | upa_writeq(ICLR_IDLE, data->iclr); | 320 | upa_writeq(ICLR_IDLE, handler_data->iclr); |
321 | } | 321 | } |
322 | 322 | ||
323 | return 0; | 323 | return 0; |
@@ -346,14 +346,14 @@ static void sun4u_irq_disable(unsigned int virt_irq) | |||
346 | 346 | ||
347 | static void sun4u_irq_eoi(unsigned int virt_irq) | 347 | static void sun4u_irq_eoi(unsigned int virt_irq) |
348 | { | 348 | { |
349 | struct irq_handler_data *data = get_irq_chip_data(virt_irq); | 349 | struct irq_handler_data *handler_data = get_irq_chip_data(virt_irq); |
350 | struct irq_desc *desc = irq_desc + virt_irq; | 350 | struct irq_desc *desc = irq_desc + virt_irq; |
351 | 351 | ||
352 | if (unlikely(desc->status & (IRQ_DISABLED|IRQ_INPROGRESS))) | 352 | if (unlikely(desc->status & (IRQ_DISABLED|IRQ_INPROGRESS))) |
353 | return; | 353 | return; |
354 | 354 | ||
355 | if (likely(data)) | 355 | if (likely(handler_data)) |
356 | upa_writeq(ICLR_IDLE, data->iclr); | 356 | upa_writeq(ICLR_IDLE, handler_data->iclr); |
357 | } | 357 | } |
358 | 358 | ||
359 | static void sun4v_irq_enable(unsigned int virt_irq) | 359 | static void sun4v_irq_enable(unsigned int virt_irq) |
@@ -530,10 +530,10 @@ static struct irq_chip sun4v_virq = { | |||
530 | static void pre_flow_handler(unsigned int virt_irq, | 530 | static void pre_flow_handler(unsigned int virt_irq, |
531 | struct irq_desc *desc) | 531 | struct irq_desc *desc) |
532 | { | 532 | { |
533 | struct irq_handler_data *data = get_irq_chip_data(virt_irq); | 533 | struct irq_handler_data *handler_data = get_irq_chip_data(virt_irq); |
534 | unsigned int ino = virt_irq_table[virt_irq].dev_ino; | 534 | unsigned int ino = virt_irq_table[virt_irq].dev_ino; |
535 | 535 | ||
536 | data->pre_handler(ino, data->arg1, data->arg2); | 536 | handler_data->pre_handler(ino, handler_data->arg1, handler_data->arg2); |
537 | 537 | ||
538 | handle_fasteoi_irq(virt_irq, desc); | 538 | handle_fasteoi_irq(virt_irq, desc); |
539 | } | 539 | } |
@@ -542,12 +542,12 @@ void irq_install_pre_handler(int virt_irq, | |||
542 | void (*func)(unsigned int, void *, void *), | 542 | void (*func)(unsigned int, void *, void *), |
543 | void *arg1, void *arg2) | 543 | void *arg1, void *arg2) |
544 | { | 544 | { |
545 | struct irq_handler_data *data = get_irq_chip_data(virt_irq); | 545 | struct irq_handler_data *handler_data = get_irq_chip_data(virt_irq); |
546 | struct irq_desc *desc = irq_desc + virt_irq; | 546 | struct irq_desc *desc = irq_desc + virt_irq; |
547 | 547 | ||
548 | data->pre_handler = func; | 548 | handler_data->pre_handler = func; |
549 | data->arg1 = arg1; | 549 | handler_data->arg1 = arg1; |
550 | data->arg2 = arg2; | 550 | handler_data->arg2 = arg2; |
551 | 551 | ||
552 | desc->handle_irq = pre_flow_handler; | 552 | desc->handle_irq = pre_flow_handler; |
553 | } | 553 | } |
@@ -555,7 +555,7 @@ void irq_install_pre_handler(int virt_irq, | |||
555 | unsigned int build_irq(int inofixup, unsigned long iclr, unsigned long imap) | 555 | unsigned int build_irq(int inofixup, unsigned long iclr, unsigned long imap) |
556 | { | 556 | { |
557 | struct ino_bucket *bucket; | 557 | struct ino_bucket *bucket; |
558 | struct irq_handler_data *data; | 558 | struct irq_handler_data *handler_data; |
559 | unsigned int virt_irq; | 559 | unsigned int virt_irq; |
560 | int ino; | 560 | int ino; |
561 | 561 | ||
@@ -573,19 +573,19 @@ unsigned int build_irq(int inofixup, unsigned long iclr, unsigned long imap) | |||
573 | "IVEC"); | 573 | "IVEC"); |
574 | } | 574 | } |
575 | 575 | ||
576 | data = get_irq_chip_data(virt_irq); | 576 | handler_data = get_irq_chip_data(virt_irq); |
577 | if (unlikely(data)) | 577 | if (unlikely(handler_data)) |
578 | goto out; | 578 | goto out; |
579 | 579 | ||
580 | data = kzalloc(sizeof(struct irq_handler_data), GFP_ATOMIC); | 580 | handler_data = kzalloc(sizeof(struct irq_handler_data), GFP_ATOMIC); |
581 | if (unlikely(!data)) { | 581 | if (unlikely(!handler_data)) { |
582 | prom_printf("IRQ: kzalloc(irq_handler_data) failed.\n"); | 582 | prom_printf("IRQ: kzalloc(irq_handler_data) failed.\n"); |
583 | prom_halt(); | 583 | prom_halt(); |
584 | } | 584 | } |
585 | set_irq_chip_data(virt_irq, data); | 585 | set_irq_chip_data(virt_irq, handler_data); |
586 | 586 | ||
587 | data->imap = imap; | 587 | handler_data->imap = imap; |
588 | data->iclr = iclr; | 588 | handler_data->iclr = iclr; |
589 | 589 | ||
590 | out: | 590 | out: |
591 | return virt_irq; | 591 | return virt_irq; |
@@ -595,7 +595,7 @@ static unsigned int sun4v_build_common(unsigned long sysino, | |||
595 | struct irq_chip *chip) | 595 | struct irq_chip *chip) |
596 | { | 596 | { |
597 | struct ino_bucket *bucket; | 597 | struct ino_bucket *bucket; |
598 | struct irq_handler_data *data; | 598 | struct irq_handler_data *handler_data; |
599 | unsigned int virt_irq; | 599 | unsigned int virt_irq; |
600 | 600 | ||
601 | BUG_ON(tlb_type != hypervisor); | 601 | BUG_ON(tlb_type != hypervisor); |
@@ -610,23 +610,23 @@ static unsigned int sun4v_build_common(unsigned long sysino, | |||
610 | "IVEC"); | 610 | "IVEC"); |
611 | } | 611 | } |
612 | 612 | ||
613 | data = get_irq_chip_data(virt_irq); | 613 | handler_data = get_irq_chip_data(virt_irq); |
614 | if (unlikely(data)) | 614 | if (unlikely(handler_data)) |
615 | goto out; | 615 | goto out; |
616 | 616 | ||
617 | data = kzalloc(sizeof(struct irq_handler_data), GFP_ATOMIC); | 617 | handler_data = kzalloc(sizeof(struct irq_handler_data), GFP_ATOMIC); |
618 | if (unlikely(!data)) { | 618 | if (unlikely(!handler_data)) { |
619 | prom_printf("IRQ: kzalloc(irq_handler_data) failed.\n"); | 619 | prom_printf("IRQ: kzalloc(irq_handler_data) failed.\n"); |
620 | prom_halt(); | 620 | prom_halt(); |
621 | } | 621 | } |
622 | set_irq_chip_data(virt_irq, data); | 622 | set_irq_chip_data(virt_irq, handler_data); |
623 | 623 | ||
624 | /* Catch accidental accesses to these things. IMAP/ICLR handling | 624 | /* Catch accidental accesses to these things. IMAP/ICLR handling |
625 | * is done by hypervisor calls on sun4v platforms, not by direct | 625 | * is done by hypervisor calls on sun4v platforms, not by direct |
626 | * register accesses. | 626 | * register accesses. |
627 | */ | 627 | */ |
628 | data->imap = ~0UL; | 628 | handler_data->imap = ~0UL; |
629 | data->iclr = ~0UL; | 629 | handler_data->iclr = ~0UL; |
630 | 630 | ||
631 | out: | 631 | out: |
632 | return virt_irq; | 632 | return virt_irq; |
@@ -641,7 +641,7 @@ unsigned int sun4v_build_irq(u32 devhandle, unsigned int devino) | |||
641 | 641 | ||
642 | unsigned int sun4v_build_virq(u32 devhandle, unsigned int devino) | 642 | unsigned int sun4v_build_virq(u32 devhandle, unsigned int devino) |
643 | { | 643 | { |
644 | struct irq_handler_data *data; | 644 | struct irq_handler_data *handler_data; |
645 | unsigned long hv_err, cookie; | 645 | unsigned long hv_err, cookie; |
646 | struct ino_bucket *bucket; | 646 | struct ino_bucket *bucket; |
647 | struct irq_desc *desc; | 647 | struct irq_desc *desc; |
@@ -669,8 +669,8 @@ unsigned int sun4v_build_virq(u32 devhandle, unsigned int devino) | |||
669 | handle_fasteoi_irq, | 669 | handle_fasteoi_irq, |
670 | "IVEC"); | 670 | "IVEC"); |
671 | 671 | ||
672 | data = kzalloc(sizeof(struct irq_handler_data), GFP_ATOMIC); | 672 | handler_data = kzalloc(sizeof(struct irq_handler_data), GFP_ATOMIC); |
673 | if (unlikely(!data)) | 673 | if (unlikely(!handler_data)) |
674 | return 0; | 674 | return 0; |
675 | 675 | ||
676 | /* In order to make the LDC channel startup sequence easier, | 676 | /* In order to make the LDC channel startup sequence easier, |
@@ -680,14 +680,14 @@ unsigned int sun4v_build_virq(u32 devhandle, unsigned int devino) | |||
680 | desc = irq_desc + virt_irq; | 680 | desc = irq_desc + virt_irq; |
681 | desc->status |= IRQ_NOAUTOEN; | 681 | desc->status |= IRQ_NOAUTOEN; |
682 | 682 | ||
683 | set_irq_chip_data(virt_irq, data); | 683 | set_irq_chip_data(virt_irq, handler_data); |
684 | 684 | ||
685 | /* Catch accidental accesses to these things. IMAP/ICLR handling | 685 | /* Catch accidental accesses to these things. IMAP/ICLR handling |
686 | * is done by hypervisor calls on sun4v platforms, not by direct | 686 | * is done by hypervisor calls on sun4v platforms, not by direct |
687 | * register accesses. | 687 | * register accesses. |
688 | */ | 688 | */ |
689 | data->imap = ~0UL; | 689 | handler_data->imap = ~0UL; |
690 | data->iclr = ~0UL; | 690 | handler_data->iclr = ~0UL; |
691 | 691 | ||
692 | cookie = ~__pa(bucket); | 692 | cookie = ~__pa(bucket); |
693 | hv_err = sun4v_vintr_set_cookie(devhandle, devino, cookie); | 693 | hv_err = sun4v_vintr_set_cookie(devhandle, devino, cookie); |