mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-02 00:29:49 -04:00
[Blackfin] arch: Fix bug - Setting peripheral_map only when dma channel is UART2/3.
Singed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
This commit is contained in:
@@ -105,13 +105,14 @@ int request_dma(unsigned int channel, char *device_id)
|
||||
mutex_unlock(&(dma_ch[channel].dmalock));
|
||||
|
||||
#ifdef CONFIG_BF54x
|
||||
if (channel >= CH_UART2_RX && channel <= CH_UART3_TX &&
|
||||
strncmp(device_id, "BFIN_UART", 9) == 0)
|
||||
dma_ch[channel].regs->peripheral_map |=
|
||||
(channel - CH_UART2_RX + 0xC);
|
||||
else
|
||||
dma_ch[channel].regs->peripheral_map |=
|
||||
(channel - CH_UART2_RX + 0x6);
|
||||
if (channel >= CH_UART2_RX && channel <= CH_UART3_TX) {
|
||||
if (strncmp(device_id, "BFIN_UART", 9) == 0)
|
||||
dma_ch[channel].regs->peripheral_map |=
|
||||
(channel - CH_UART2_RX + 0xC);
|
||||
else
|
||||
dma_ch[channel].regs->peripheral_map |=
|
||||
(channel - CH_UART2_RX + 0x6);
|
||||
}
|
||||
#endif
|
||||
|
||||
dma_ch[channel].device_id = device_id;
|
||||
|
||||
Reference in New Issue
Block a user