aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLuke Browning <lukebr@linux.vnet.ibm.com>2008-04-27 14:41:55 -0400
committerJeremy Kerr <jk@ozlabs.org>2008-05-04 23:33:44 -0400
commitf3d69e0507f84903059d456c5d19f10b2df3ac69 (patch)
treef8aa4062bc1a0939d7bdb3a634c01869f2bb32a2 /include
parent7a2142002f29a7b398c49da9bdec712dc57087c7 (diff)
[POWERPC] spufs: fix concurrent delivery of class 0 & 1 exceptions
SPU class 0 & 1 exceptions may occur in parallel, so we may end up overwriting csa.dsisr. This change adds dedicated fields for each class to the spu and the spu context so that fault data is not overwritten. Signed-off-by: Luke Browning <lukebr@linux.vnet.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'include')
-rw-r--r--include/asm-powerpc/spu.h8
-rw-r--r--include/asm-powerpc/spu_csa.h3
2 files changed, 7 insertions, 4 deletions
diff --git a/include/asm-powerpc/spu.h b/include/asm-powerpc/spu.h
index e3c845b0f764..882aa953968a 100644
--- a/include/asm-powerpc/spu.h
+++ b/include/asm-powerpc/spu.h
@@ -128,9 +128,11 @@ struct spu {
128 unsigned int irqs[3]; 128 unsigned int irqs[3];
129 u32 node; 129 u32 node;
130 u64 flags; 130 u64 flags;
131 u64 dar;
132 u64 dsisr;
133 u64 class_0_pending; 131 u64 class_0_pending;
132 u64 class_0_dar;
133 u64 class_0_dsisr;
134 u64 class_1_dar;
135 u64 class_1_dsisr;
134 size_t ls_size; 136 size_t ls_size;
135 unsigned int slb_replace; 137 unsigned int slb_replace;
136 struct mm_struct *mm; 138 struct mm_struct *mm;
@@ -143,7 +145,7 @@ struct spu {
143 145
144 void (* wbox_callback)(struct spu *spu); 146 void (* wbox_callback)(struct spu *spu);
145 void (* ibox_callback)(struct spu *spu); 147 void (* ibox_callback)(struct spu *spu);
146 void (* stop_callback)(struct spu *spu); 148 void (* stop_callback)(struct spu *spu, int irq);
147 void (* mfc_callback)(struct spu *spu); 149 void (* mfc_callback)(struct spu *spu);
148 150
149 char irq_c0[8]; 151 char irq_c0[8];
diff --git a/include/asm-powerpc/spu_csa.h b/include/asm-powerpc/spu_csa.h
index 0ab6bff86078..129ec148d451 100644
--- a/include/asm-powerpc/spu_csa.h
+++ b/include/asm-powerpc/spu_csa.h
@@ -254,7 +254,8 @@ struct spu_state {
254 u64 spu_chnldata_RW[32]; 254 u64 spu_chnldata_RW[32];
255 u32 spu_mailbox_data[4]; 255 u32 spu_mailbox_data[4];
256 u32 pu_mailbox_data[1]; 256 u32 pu_mailbox_data[1];
257 u64 dar, dsisr, class_0_pending; 257 u64 class_0_dar, class_0_dsisr, class_0_pending;
258 u64 class_1_dar, class_1_dsisr;
258 unsigned long suspend_time; 259 unsigned long suspend_time;
259 spinlock_t register_lock; 260 spinlock_t register_lock;
260}; 261};