Title: [3981] trunk/sound/soc/blackfin: Bug[#3727] hook DMA to head of normal buffer ring as a workaround, since the next descriptor is always dummy descriptor that causes no sound after recover from sport error
Revision
3981
Author
cliff
Date
2007-12-04 18:52:08 -0600 (Tue, 04 Dec 2007)

Log Message

Bug[#3727]hook DMA to head of normal buffer ring as a workaround,since the next descriptor is always dummy descriptor that causes no sound after recover from sport error

Diffstat

 bf5xx-sport.c |   22 ++--------------------
 bf5xx-sport.h |    3 +--
 2 files changed, 3 insertions(+), 22 deletions(-)

Modified Paths

Diff

Modified: trunk/sound/soc/blackfin/bf5xx-sport.c (3980 => 3981)


--- trunk/sound/soc/blackfin/bf5xx-sport.c	2007-12-04 16:57:43 UTC (rev 3980)
+++ trunk/sound/soc/blackfin/bf5xx-sport.c	2007-12-05 00:52:08 UTC (rev 3981)
@@ -697,7 +697,6 @@
 	if (!(rx_stat & DMA_DONE)) {
 		printk(KERN_ERR "rx dma is already stopped\n");
 	}
-	sport->rx_next_desc = get_dma_next_desc_ptr(sport->dma_rx_chan);
 	if (sport->rx_callback) {
 		sport->rx_callback(sport->rx_data);
 		return IRQ_HANDLED;
@@ -716,7 +715,6 @@
 		printk(KERN_ERR "tx dma is already stopped\n");
 		return IRQ_HANDLED;
 	}
-	sport->tx_next_desc = get_dma_next_desc_ptr(sport->dma_tx_chan);
 	if (sport->tx_callback) {
 		sport->tx_callback(sport->tx_data);
 		return IRQ_HANDLED;
@@ -744,27 +742,11 @@
 				status & RUVF ? " RUVF" : "");
 		if (status & TOVF || status & TUVF) {
 			disable_dma(sport->dma_tx_chan);
-			set_dma_next_desc_addr(sport->dma_tx_chan, \
-				sport->tx_next_desc);
-			set_dma_x_count(sport->dma_tx_chan, 0);
-			set_dma_x_modify(sport->dma_tx_chan, 0);
-			set_dma_config(sport->dma_tx_chan, (DMAFLOW_LARGE | \
-				NDSIZE_9 | WDSIZE_16));
-			set_dma_curr_addr(sport->dma_tx_chan, \
-				((struct dmasg *)sport->tx_next_desc)->start_addr);
-			SSYNC();
+			sport_tx_dma_start(sport, 0);
 			enable_dma(sport->dma_tx_chan);
 		} else {
 			disable_dma(sport->dma_rx_chan);
-			set_dma_next_desc_addr(sport->dma_rx_chan, \
-				sport->rx_next_desc);
-			set_dma_x_count(sport->dma_rx_chan, 0);
-			set_dma_x_modify(sport->dma_rx_chan, 0);
-			set_dma_config(sport->dma_rx_chan, (DMAFLOW_LARGE | \
-				NDSIZE_9 | WDSIZE_16 | WNR));
-			set_dma_curr_addr(sport->dma_rx_chan, \
-				((struct dmasg *)sport->rx_next_desc)->start_addr);
-			SSYNC();
+			sport_rx_dma_start(sport, 0);
 			enable_dma(sport->dma_rx_chan);
 
 		}

Modified: trunk/sound/soc/blackfin/bf5xx-sport.h (3980 => 3981)


--- trunk/sound/soc/blackfin/bf5xx-sport.h	2007-12-04 16:57:43 UTC (rev 3980)
+++ trunk/sound/soc/blackfin/bf5xx-sport.h	2007-12-05 00:52:08 UTC (rev 3981)
@@ -114,8 +114,7 @@
 	void *tx_data;
 	void (*err_callback)(void *data);
 	void *err_data;
-	unsigned long rx_next_desc;
-	unsigned long tx_next_desc;
+
 	void *private_data;
 };
 
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
http://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits

Reply via email to