Skip to content

Commit

Permalink
[CELL] spufs: fix decr_status meanings
Browse files Browse the repository at this point in the history
The decr_status in the LSCSA is confusedly used as two meanings:
 * SPU decrementer was running
 * SPU decrementer was wrapped as a result of adjust
and the code to set decr_status is missing.

This patch fixes these problems by using the decr_status argument as a
set of flags. This requires a rebuild of the shipped spu_restore code.

Signed-off-by: Masato Noguchi <Masato.Noguchi@jp.sony.com>
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
  • Loading branch information
Masato Noguchi authored and Arnd Bergmann committed Jul 20, 2007
1 parent cfd529b commit 1cfc0f8
Show file tree
Hide file tree
Showing 4 changed files with 269 additions and 223 deletions.
2 changes: 1 addition & 1 deletion arch/powerpc/platforms/cell/spufs/spu_restore.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ static inline void restore_decr(void)
* decrementer value from LSCSA.
*/
offset = LSCSA_QW_OFFSET(decr_status);
decr_running = regs_spill[offset].slot[0];
decr_running = regs_spill[offset].slot[0] & SPU_DECR_STATUS_RUNNING;
if (decr_running) {
offset = LSCSA_QW_OFFSET(decr);
decr = regs_spill[offset].slot[0];
Expand Down
Loading

0 comments on commit 1cfc0f8

Please sign in to comment.