mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-19 00:54:41 +08:00
[PATCH] cpm_uart: use DPRAM for early console
m8xx_cpm_hostalloc() can't rely on using the coherent DMA allocator early on boot because the VM is not fully up yet. Change it to use the on-board DPRAM instead. The current code relies on the "bootmem_page" allocated by m8xx_cpm_reset(), which must be killed. This is done in v2.4 but has never been forward ported to v2.6. Signed-off-by: Marcelo Tosatti <marcelo.tosatti@cyclades.com> Cc: Pantelis Antoniou <panto@intracom.gr> Cc: Kumar Gala <kumar.gala@freescale.com> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
6ddcc9197b
commit
4e4b7952cd
@ -185,7 +185,7 @@ int cpm_uart_allocbuf(struct uart_cpm_port *pinfo, unsigned int is_con)
|
|||||||
memsz = L1_CACHE_ALIGN(pinfo->rx_nrfifos * pinfo->rx_fifosize) +
|
memsz = L1_CACHE_ALIGN(pinfo->rx_nrfifos * pinfo->rx_fifosize) +
|
||||||
L1_CACHE_ALIGN(pinfo->tx_nrfifos * pinfo->tx_fifosize);
|
L1_CACHE_ALIGN(pinfo->tx_nrfifos * pinfo->tx_fifosize);
|
||||||
if (is_con) {
|
if (is_con) {
|
||||||
mem_addr = (u8 *) m8xx_cpm_hostalloc(memsz);
|
mem_addr = (u8 *) cpm_dpram_addr(cpm_dpalloc(memsz, 8));
|
||||||
dma_addr = 0;
|
dma_addr = 0;
|
||||||
} else
|
} else
|
||||||
mem_addr = dma_alloc_coherent(NULL, memsz, &dma_addr,
|
mem_addr = dma_alloc_coherent(NULL, memsz, &dma_addr,
|
||||||
|
Loading…
Reference in New Issue
Block a user