diff options
-rw-r--r-- | arch/powerpc/platforms/cell/spufs/switch.c | 20 | ||||
-rw-r--r-- | include/asm-powerpc/spu.h | 2 |
2 files changed, 12 insertions, 10 deletions
diff --git a/arch/powerpc/platforms/cell/spufs/switch.c b/arch/powerpc/platforms/cell/spufs/switch.c index 1a7d7a0f66fc..6063c88c26d2 100644 --- a/arch/powerpc/platforms/cell/spufs/switch.c +++ b/arch/powerpc/platforms/cell/spufs/switch.c | |||
@@ -740,9 +740,9 @@ static inline void enable_interrupts(struct spu_state *csa, struct spu *spu) | |||
740 | * (translation) interrupts. | 740 | * (translation) interrupts. |
741 | */ | 741 | */ |
742 | spin_lock_irq(&spu->register_lock); | 742 | spin_lock_irq(&spu->register_lock); |
743 | spu_int_stat_clear(spu, 0, ~0ul); | 743 | spu_int_stat_clear(spu, 0, CLASS0_INTR_MASK); |
744 | spu_int_stat_clear(spu, 1, ~0ul); | 744 | spu_int_stat_clear(spu, 1, CLASS1_INTR_MASK); |
745 | spu_int_stat_clear(spu, 2, ~0ul); | 745 | spu_int_stat_clear(spu, 2, CLASS2_INTR_MASK); |
746 | spu_int_mask_set(spu, 0, 0ul); | 746 | spu_int_mask_set(spu, 0, 0ul); |
747 | spu_int_mask_set(spu, 1, class1_mask); | 747 | spu_int_mask_set(spu, 1, class1_mask); |
748 | spu_int_mask_set(spu, 2, 0ul); | 748 | spu_int_mask_set(spu, 2, 0ul); |
@@ -899,8 +899,8 @@ static inline void wait_tag_complete(struct spu_state *csa, struct spu *spu) | |||
899 | POLL_WHILE_FALSE(in_be32(&prob->dma_tagstatus_R) & mask); | 899 | POLL_WHILE_FALSE(in_be32(&prob->dma_tagstatus_R) & mask); |
900 | 900 | ||
901 | local_irq_save(flags); | 901 | local_irq_save(flags); |
902 | spu_int_stat_clear(spu, 0, ~(0ul)); | 902 | spu_int_stat_clear(spu, 0, CLASS0_INTR_MASK); |
903 | spu_int_stat_clear(spu, 2, ~(0ul)); | 903 | spu_int_stat_clear(spu, 2, CLASS2_INTR_MASK); |
904 | local_irq_restore(flags); | 904 | local_irq_restore(flags); |
905 | } | 905 | } |
906 | 906 | ||
@@ -918,8 +918,8 @@ static inline void wait_spu_stopped(struct spu_state *csa, struct spu *spu) | |||
918 | POLL_WHILE_TRUE(in_be32(&prob->spu_status_R) & SPU_STATUS_RUNNING); | 918 | POLL_WHILE_TRUE(in_be32(&prob->spu_status_R) & SPU_STATUS_RUNNING); |
919 | 919 | ||
920 | local_irq_save(flags); | 920 | local_irq_save(flags); |
921 | spu_int_stat_clear(spu, 0, ~(0ul)); | 921 | spu_int_stat_clear(spu, 0, CLASS0_INTR_MASK); |
922 | spu_int_stat_clear(spu, 2, ~(0ul)); | 922 | spu_int_stat_clear(spu, 2, CLASS2_INTR_MASK); |
923 | local_irq_restore(flags); | 923 | local_irq_restore(flags); |
924 | } | 924 | } |
925 | 925 | ||
@@ -1395,9 +1395,9 @@ static inline void clear_interrupts(struct spu_state *csa, struct spu *spu) | |||
1395 | spu_int_mask_set(spu, 0, 0ul); | 1395 | spu_int_mask_set(spu, 0, 0ul); |
1396 | spu_int_mask_set(spu, 1, 0ul); | 1396 | spu_int_mask_set(spu, 1, 0ul); |
1397 | spu_int_mask_set(spu, 2, 0ul); | 1397 | spu_int_mask_set(spu, 2, 0ul); |
1398 | spu_int_stat_clear(spu, 0, ~0ul); | 1398 | spu_int_stat_clear(spu, 0, CLASS0_INTR_MASK); |
1399 | spu_int_stat_clear(spu, 1, ~0ul); | 1399 | spu_int_stat_clear(spu, 1, CLASS1_INTR_MASK); |
1400 | spu_int_stat_clear(spu, 2, ~0ul); | 1400 | spu_int_stat_clear(spu, 2, CLASS2_INTR_MASK); |
1401 | spin_unlock_irq(&spu->register_lock); | 1401 | spin_unlock_irq(&spu->register_lock); |
1402 | } | 1402 | } |
1403 | 1403 | ||
diff --git a/include/asm-powerpc/spu.h b/include/asm-powerpc/spu.h index 277460476aec..5ca30e2e2639 100644 --- a/include/asm-powerpc/spu.h +++ b/include/asm-powerpc/spu.h | |||
@@ -535,11 +535,13 @@ struct spu_priv1 { | |||
535 | #define CLASS1_STORAGE_FAULT_INTR 0x2L | 535 | #define CLASS1_STORAGE_FAULT_INTR 0x2L |
536 | #define CLASS1_LS_COMPARE_SUSPEND_ON_GET_INTR 0x4L | 536 | #define CLASS1_LS_COMPARE_SUSPEND_ON_GET_INTR 0x4L |
537 | #define CLASS1_LS_COMPARE_SUSPEND_ON_PUT_INTR 0x8L | 537 | #define CLASS1_LS_COMPARE_SUSPEND_ON_PUT_INTR 0x8L |
538 | #define CLASS1_INTR_MASK 0xfL | ||
538 | #define CLASS2_MAILBOX_INTR 0x1L | 539 | #define CLASS2_MAILBOX_INTR 0x1L |
539 | #define CLASS2_SPU_STOP_INTR 0x2L | 540 | #define CLASS2_SPU_STOP_INTR 0x2L |
540 | #define CLASS2_SPU_HALT_INTR 0x4L | 541 | #define CLASS2_SPU_HALT_INTR 0x4L |
541 | #define CLASS2_SPU_DMA_TAG_GROUP_COMPLETE_INTR 0x8L | 542 | #define CLASS2_SPU_DMA_TAG_GROUP_COMPLETE_INTR 0x8L |
542 | #define CLASS2_MAILBOX_THRESHOLD_INTR 0x10L | 543 | #define CLASS2_MAILBOX_THRESHOLD_INTR 0x10L |
544 | #define CLASS2_INTR_MASK 0x1fL | ||
543 | u8 pad_0x158_0x180[0x28]; /* 0x158 */ | 545 | u8 pad_0x158_0x180[0x28]; /* 0x158 */ |
544 | u64 int_route_RW; /* 0x180 */ | 546 | u64 int_route_RW; /* 0x180 */ |
545 | 547 | ||