]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[POWERPC] spufs: save MFC command channel before purging MFC queue
authorJeremy Kerr <jk@ozlabs.org>
Thu, 27 Mar 2008 03:59:58 +0000 (14:59 +1100)
committerJeremy Kerr <jk@ozlabs.org>
Fri, 28 Mar 2008 03:36:08 +0000 (14:36 +1100)
During the context save process, we currently save the MFC command
channel after purging the MFC queues. This causes a systemsim warning,
as the command channel may be in an unknown state after the purge.

This change does the save before purging the MFC queues.

Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
arch/powerpc/platforms/cell/spufs/switch.c

index e9dc7a55d1b9466d5f5e5597371a79789b46ed30..d2a1249d36dd2a7bc018727e09c3b7c57b88cf1c 100644 (file)
@@ -1815,6 +1815,7 @@ static void save_csa(struct spu_state *prev, struct spu *spu)
        save_mfc_csr_ato(prev, spu);    /* Step 24. */
        save_mfc_tclass_id(prev, spu);  /* Step 25. */
        set_mfc_tclass_id(prev, spu);   /* Step 26. */
+       save_mfc_cmd(prev, spu);        /* Step 26a - moved from 44. */
        purge_mfc_queue(prev, spu);     /* Step 27. */
        wait_purge_complete(prev, spu); /* Step 28. */
        setup_mfc_sr1(prev, spu);       /* Step 30. */
@@ -1831,7 +1832,6 @@ static void save_csa(struct spu_state *prev, struct spu *spu)
        save_ppuint_mb(prev, spu);      /* Step 41. */
        save_ch_part1(prev, spu);       /* Step 42. */
        save_spu_mb(prev, spu);         /* Step 43. */
-       save_mfc_cmd(prev, spu);        /* Step 44. */
        reset_ch(prev, spu);            /* Step 45. */
 }