Commit 7ed43f6a authored by Graf Yang's avatar Graf Yang Committed by Greg Kroah-Hartman

serial: bfin_5xx: need to disable DMA TX interrupt too

If we don't disable the DMA TX channel, an inopportune timeout will
trigger the interrupt handler and may cause a dead lock with the spin_lock.
Signed-off-by: default avatarGraf Yang <graf.yang@analog.com>
Signed-off-by: default avatarMike Frysinger <vapier@gentoo.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent b2ced4f6
...@@ -488,6 +488,7 @@ void bfin_serial_rx_dma_timeout(struct bfin_serial_port *uart) ...@@ -488,6 +488,7 @@ void bfin_serial_rx_dma_timeout(struct bfin_serial_port *uart)
{ {
int x_pos, pos; int x_pos, pos;
dma_disable_irq(uart->tx_dma_channel);
dma_disable_irq(uart->rx_dma_channel); dma_disable_irq(uart->rx_dma_channel);
spin_lock_bh(&uart->port.lock); spin_lock_bh(&uart->port.lock);
...@@ -521,6 +522,7 @@ void bfin_serial_rx_dma_timeout(struct bfin_serial_port *uart) ...@@ -521,6 +522,7 @@ void bfin_serial_rx_dma_timeout(struct bfin_serial_port *uart)
} }
spin_unlock_bh(&uart->port.lock); spin_unlock_bh(&uart->port.lock);
dma_enable_irq(uart->tx_dma_channel);
dma_enable_irq(uart->rx_dma_channel); dma_enable_irq(uart->rx_dma_channel);
mod_timer(&(uart->rx_dma_timer), jiffies + DMA_RX_FLUSH_JIFFIES); mod_timer(&(uart->rx_dma_timer), jiffies + DMA_RX_FLUSH_JIFFIES);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment