aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/ps3/interrupt.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/platforms/ps3/interrupt.c')
-rw-r--r--arch/powerpc/platforms/ps3/interrupt.c28
1 files changed, 15 insertions, 13 deletions
diff --git a/arch/powerpc/platforms/ps3/interrupt.c b/arch/powerpc/platforms/ps3/interrupt.c
index e59634f7af96..8ec5ccf76b19 100644
--- a/arch/powerpc/platforms/ps3/interrupt.c
+++ b/arch/powerpc/platforms/ps3/interrupt.c
@@ -60,6 +60,8 @@
60 * gives a usable range of plug values of {NUM_ISA_INTERRUPTS..63}. Note 60 * gives a usable range of plug values of {NUM_ISA_INTERRUPTS..63}. Note
61 * that there is no constraint on how many in this set an individual thread 61 * that there is no constraint on how many in this set an individual thread
62 * can acquire. 62 * can acquire.
63 *
64 * The mask is declared as unsigned long so we can use set/clear_bit on it.
63 */ 65 */
64 66
65#define PS3_BMP_MINALIGN 64 67#define PS3_BMP_MINALIGN 64
@@ -68,7 +70,7 @@ struct ps3_bmp {
68 struct { 70 struct {
69 u64 status; 71 u64 status;
70 u64 unused_1[3]; 72 u64 unused_1[3];
71 u64 mask; 73 unsigned long mask;
72 u64 unused_2[3]; 74 u64 unused_2[3];
73 }; 75 };
74 u64 ipi_debug_brk_mask; 76 u64 ipi_debug_brk_mask;
@@ -102,7 +104,7 @@ static void ps3_chip_mask(unsigned int virq)
102 struct ps3_private *pd = get_irq_chip_data(virq); 104 struct ps3_private *pd = get_irq_chip_data(virq);
103 unsigned long flags; 105 unsigned long flags;
104 106
105 pr_debug("%s:%d: thread_id %lu, virq %d\n", __func__, __LINE__, 107 pr_debug("%s:%d: thread_id %llu, virq %d\n", __func__, __LINE__,
106 pd->thread_id, virq); 108 pd->thread_id, virq);
107 109
108 local_irq_save(flags); 110 local_irq_save(flags);
@@ -123,7 +125,7 @@ static void ps3_chip_unmask(unsigned int virq)
123 struct ps3_private *pd = get_irq_chip_data(virq); 125 struct ps3_private *pd = get_irq_chip_data(virq);
124 unsigned long flags; 126 unsigned long flags;
125 127
126 pr_debug("%s:%d: thread_id %lu, virq %d\n", __func__, __LINE__, 128 pr_debug("%s:%d: thread_id %llu, virq %d\n", __func__, __LINE__,
127 pd->thread_id, virq); 129 pd->thread_id, virq);
128 130
129 local_irq_save(flags); 131 local_irq_save(flags);
@@ -221,7 +223,7 @@ static int ps3_virq_destroy(unsigned int virq)
221{ 223{
222 const struct ps3_private *pd = get_irq_chip_data(virq); 224 const struct ps3_private *pd = get_irq_chip_data(virq);
223 225
224 pr_debug("%s:%d: ppe_id %lu, thread_id %lu, virq %u\n", __func__, 226 pr_debug("%s:%d: ppe_id %llu, thread_id %llu, virq %u\n", __func__,
225 __LINE__, pd->ppe_id, pd->thread_id, virq); 227 __LINE__, pd->ppe_id, pd->thread_id, virq);
226 228
227 set_irq_chip_data(virq, NULL); 229 set_irq_chip_data(virq, NULL);
@@ -291,7 +293,7 @@ int ps3_irq_plug_destroy(unsigned int virq)
291 int result; 293 int result;
292 const struct ps3_private *pd = get_irq_chip_data(virq); 294 const struct ps3_private *pd = get_irq_chip_data(virq);
293 295
294 pr_debug("%s:%d: ppe_id %lu, thread_id %lu, virq %u\n", __func__, 296 pr_debug("%s:%d: ppe_id %llu, thread_id %llu, virq %u\n", __func__,
295 __LINE__, pd->ppe_id, pd->thread_id, virq); 297 __LINE__, pd->ppe_id, pd->thread_id, virq);
296 298
297 ps3_chip_mask(virq); 299 ps3_chip_mask(virq);
@@ -322,7 +324,7 @@ EXPORT_SYMBOL_GPL(ps3_irq_plug_destroy);
322int ps3_event_receive_port_setup(enum ps3_cpu_binding cpu, unsigned int *virq) 324int ps3_event_receive_port_setup(enum ps3_cpu_binding cpu, unsigned int *virq)
323{ 325{
324 int result; 326 int result;
325 unsigned long outlet; 327 u64 outlet;
326 328
327 result = lv1_construct_event_receive_port(&outlet); 329 result = lv1_construct_event_receive_port(&outlet);
328 330
@@ -468,7 +470,7 @@ int ps3_io_irq_setup(enum ps3_cpu_binding cpu, unsigned int interrupt_id,
468 unsigned int *virq) 470 unsigned int *virq)
469{ 471{
470 int result; 472 int result;
471 unsigned long outlet; 473 u64 outlet;
472 474
473 result = lv1_construct_io_irq_outlet(interrupt_id, &outlet); 475 result = lv1_construct_io_irq_outlet(interrupt_id, &outlet);
474 476
@@ -525,7 +527,7 @@ int ps3_vuart_irq_setup(enum ps3_cpu_binding cpu, void* virt_addr_bmp,
525 unsigned int *virq) 527 unsigned int *virq)
526{ 528{
527 int result; 529 int result;
528 unsigned long outlet; 530 u64 outlet;
529 u64 lpar_addr; 531 u64 lpar_addr;
530 532
531 BUG_ON(!is_kernel_addr((u64)virt_addr_bmp)); 533 BUG_ON(!is_kernel_addr((u64)virt_addr_bmp));
@@ -581,7 +583,7 @@ int ps3_spe_irq_setup(enum ps3_cpu_binding cpu, unsigned long spe_id,
581 unsigned int class, unsigned int *virq) 583 unsigned int class, unsigned int *virq)
582{ 584{
583 int result; 585 int result;
584 unsigned long outlet; 586 u64 outlet;
585 587
586 BUG_ON(class > 2); 588 BUG_ON(class > 2);
587 589
@@ -691,7 +693,7 @@ void __init ps3_register_ipi_debug_brk(unsigned int cpu, unsigned int virq)
691 693
692 pd->bmp.ipi_debug_brk_mask = 0x8000000000000000UL >> virq; 694 pd->bmp.ipi_debug_brk_mask = 0x8000000000000000UL >> virq;
693 695
694 pr_debug("%s:%d: cpu %u, virq %u, mask %lxh\n", __func__, __LINE__, 696 pr_debug("%s:%d: cpu %u, virq %u, mask %llxh\n", __func__, __LINE__,
695 cpu, virq, pd->bmp.ipi_debug_brk_mask); 697 cpu, virq, pd->bmp.ipi_debug_brk_mask);
696} 698}
697 699
@@ -710,7 +712,7 @@ static unsigned int ps3_get_irq(void)
710 plug &= 0x3f; 712 plug &= 0x3f;
711 713
712 if (unlikely(plug == NO_IRQ)) { 714 if (unlikely(plug == NO_IRQ)) {
713 pr_debug("%s:%d: no plug found: thread_id %lu\n", __func__, 715 pr_debug("%s:%d: no plug found: thread_id %llu\n", __func__,
714 __LINE__, pd->thread_id); 716 __LINE__, pd->thread_id);
715 dump_bmp(&per_cpu(ps3_private, 0)); 717 dump_bmp(&per_cpu(ps3_private, 0));
716 dump_bmp(&per_cpu(ps3_private, 1)); 718 dump_bmp(&per_cpu(ps3_private, 1));
@@ -745,7 +747,7 @@ void __init ps3_init_IRQ(void)
745 pd->thread_id = get_hard_smp_processor_id(cpu); 747 pd->thread_id = get_hard_smp_processor_id(cpu);
746 spin_lock_init(&pd->bmp.lock); 748 spin_lock_init(&pd->bmp.lock);
747 749
748 pr_debug("%s:%d: ppe_id %lu, thread_id %lu, bmp %lxh\n", 750 pr_debug("%s:%d: ppe_id %llu, thread_id %llu, bmp %lxh\n",
749 __func__, __LINE__, pd->ppe_id, pd->thread_id, 751 __func__, __LINE__, pd->ppe_id, pd->thread_id,
750 ps3_mm_phys_to_lpar(__pa(&pd->bmp))); 752 ps3_mm_phys_to_lpar(__pa(&pd->bmp)));
751 753
@@ -770,6 +772,6 @@ void ps3_shutdown_IRQ(int cpu)
770 lv1_get_logical_ppe_id(&ppe_id); 772 lv1_get_logical_ppe_id(&ppe_id);
771 result = lv1_configure_irq_state_bitmap(ppe_id, thread_id, 0); 773 result = lv1_configure_irq_state_bitmap(ppe_id, thread_id, 0);
772 774
773 DBG("%s:%d: lv1_configure_irq_state_bitmap (%lu:%lu/%d) %s\n", __func__, 775 DBG("%s:%d: lv1_configure_irq_state_bitmap (%llu:%llu/%d) %s\n", __func__,
774 __LINE__, ppe_id, thread_id, cpu, ps3_result(result)); 776 __LINE__, ppe_id, thread_id, cpu, ps3_result(result));
775} 777}