[POWERPC] spufs: Return correct event for data storage interrupt
authorArnd Bergmann <arnd@arndb.de>
Mon, 20 Nov 2006 17:45:03 +0000 (18:45 +0100)
committerPaul Mackerras <paulus@samba.org>
Mon, 4 Dec 2006 09:39:54 +0000 (20:39 +1100)
When we attempt an MFC DMA to an unmapped address, the event
returned from spu_run should be SPE_EVENT_SPE_DATA_STORAGE,
not SPE_EVENT_INVALID_DMA.

Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/platforms/cell/spu_base.c
arch/powerpc/platforms/cell/spufs/run.c

index 56ff8b36103d51342a22708b13d42c385066c9e3..d4f4f396288fd2d69969f99ce83a7192e40f4cdc 100644 (file)
@@ -507,7 +507,7 @@ int spu_irq_class_1_bottom(struct spu *spu)
        if (!error) {
                spu_restart_dma(spu);
        } else {
-               __spu_trap_invalid_dma(spu);
+               spu->dma_callback(spu, SPE_EVENT_SPE_DATA_STORAGE);
        }
        return ret;
 }
index a4a0080c22335da1fdbea413963007db996c6a95..88a41d83a79befd17445b3d2cdc89f5511b26c8c 100644 (file)
@@ -26,6 +26,7 @@ void spufs_dma_callback(struct spu *spu, int type)
        } else {
                switch (type) {
                case SPE_EVENT_DMA_ALIGNMENT:
+               case SPE_EVENT_SPE_DATA_STORAGE:
                case SPE_EVENT_INVALID_DMA:
                        force_sig(SIGBUS, /* info, */ current);
                        break;