]> nv-tegra.nvidia Code Review - linux-2.6.git/blobdiff - arch/powerpc/platforms/cell/spufs/switch.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
[linux-2.6.git] / arch / powerpc / platforms / cell / spufs / switch.c
index a656d810a44aa6b6f34690deefd4dc8c65c617ab..c7fea2cca5346fbbd675233bc2506fd1adc9576b 100644 (file)
@@ -464,7 +464,8 @@ static inline void wait_purge_complete(struct spu_state *csa, struct spu *spu)
         *     Poll MFC_CNTL[Ps] until value '11' is read
         *     (purge complete).
         */
-       POLL_WHILE_FALSE(in_be64(&priv2->mfc_control_RW) &
+       POLL_WHILE_FALSE((in_be64(&priv2->mfc_control_RW) &
+                        MFC_CNTL_PURGE_DMA_STATUS_MASK) ==
                         MFC_CNTL_PURGE_DMA_COMPLETE);
 }
 
@@ -1028,7 +1029,8 @@ static inline void wait_suspend_mfc_complete(struct spu_state *csa,
         * Restore, Step 47.
         *     Poll MFC_CNTL[Ss] until 11 is returned.
         */
-       POLL_WHILE_FALSE(in_be64(&priv2->mfc_control_RW) &
+       POLL_WHILE_FALSE((in_be64(&priv2->mfc_control_RW) &
+                        MFC_CNTL_SUSPEND_DMA_STATUS_MASK) ==
                         MFC_CNTL_SUSPEND_COMPLETE);
 }