summaryrefslogtreecommitdiffstats
path: root/arch/blackfin
diff options
context:
space:
mode:
authorGraf Yang <graf.yang@analog.com>2008-04-25 03:10:04 +0800
committerBryan Wu <cooloney@kernel.org>2008-04-25 03:10:04 +0800
commit565c0d3ff438d18aa8c3201979fb1f5d1872ab11 (patch)
tree8a9984e69dbc4f03fd985b8b013361c89177f550 /arch/blackfin
parent5be36d22b28f01e5074f78b29aa6128da0a53641 (diff)
[Blackfin] arch: fix bug - before assign new channel to the map register, need clear the bits first.
http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=2445 Signed-off-by: Graf Yang <graf.yang@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch/blackfin')
-rw-r--r--arch/blackfin/kernel/bfin_dma_5xx.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/blackfin/kernel/bfin_dma_5xx.c b/arch/blackfin/kernel/bfin_dma_5xx.c
index df4d2a5b8e3..fd5448d6107 100644
--- a/arch/blackfin/kernel/bfin_dma_5xx.c
+++ b/arch/blackfin/kernel/bfin_dma_5xx.c
@@ -106,12 +106,15 @@ int request_dma(unsigned int channel, char *device_id)
#ifdef CONFIG_BF54x
if (channel >= CH_UART2_RX && channel <= CH_UART3_TX) {
- if (strncmp(device_id, "BFIN_UART", 9) == 0)
+ if (strncmp(device_id, "BFIN_UART", 9) == 0) {
+ dma_ch[channel].regs->peripheral_map &= 0x0FFF;
dma_ch[channel].regs->peripheral_map |=
((channel - CH_UART2_RX + 0xC)<<12);
- else
+ } else {
+ dma_ch[channel].regs->peripheral_map &= 0x0FFF;
dma_ch[channel].regs->peripheral_map |=
((channel - CH_UART2_RX + 0x6)<<12);
+ }
}
#endif