Merge branch 'stable/swiotlb-0.9' of git://git.kernel.org/pub/scm/linux/kernel/git...
[pandora-kernel.git] / arch / arm / mach-ep93xx / dma-m2p.c
index dbcac9c..a696d35 100644 (file)
@@ -28,6 +28,8 @@
  * with this implementation.
  */
 
+#define pr_fmt(fmt) "ep93xx " KBUILD_MODNAME ": " fmt
+
 #include <linux/kernel.h>
 #include <linux/clk.h>
 #include <linux/err.h>
@@ -173,7 +175,7 @@ static irqreturn_t m2p_irq(int irq, void *dev_id)
 
        switch (m2p_channel_state(ch)) {
        case STATE_IDLE:
-               pr_crit("m2p_irq: dma interrupt without a dma buffer\n");
+               pr_crit("dma interrupt without a dma buffer\n");
                BUG();
                break;
 
@@ -197,7 +199,7 @@ static irqreturn_t m2p_irq(int irq, void *dev_id)
                break;
 
        case STATE_NEXT:
-               pr_crit("m2p_irq: dma interrupt while next\n");
+               pr_crit("dma interrupt while next\n");
                BUG();
                break;
        }
@@ -274,7 +276,7 @@ static void channel_disable(struct m2p_channel *ch)
        v &= ~(M2P_CONTROL_STALL_IRQ_EN | M2P_CONTROL_NFB_IRQ_EN);
        m2p_set_control(ch, v);
 
-       while (m2p_channel_state(ch) == STATE_ON)
+       while (m2p_channel_state(ch) >= STATE_ON)
                cpu_relax();
 
        m2p_set_control(ch, 0x0);