Skip to contentSkip to conversation

cpm_uart: use dpram for early console

PATCH Marcelo Tosatti 1 participant 1 message Jun 27, 2005

lore
Share & tools
lore
#0 lore raw

Panto, Kumar,

Can something semantically equivalent to this be merged please.

m8xx_cpm_hostalloc() can't rely on using the coherent DMA allocator early on boot because the VM is not fully up yet.

The current code relies on the "bootmem_page" allocated by m8xx_cpm_reset(), which must be killed.

cpm_uart_cpm1.c 2005-06-27 17:55:45.000000000 -0300 renamed from cpm_uart_cpm1.c.orig 2005-06-27 17:51:53.000000000 -0300 +1 -1
@@ -155,7 +155,7 @@
        memsz = L1_CACHE_ALIGN(pinfo->rx_nrfifos * pinfo->rx_fifosize) +
            L1_CACHE_ALIGN(pinfo->tx_nrfifos * pinfo->tx_fifosize);
        if (is_con) {
-               mem_addr = (u8 *) m8xx_cpm_hostalloc(memsz);
+               mem_addr = (u8 *) cpm_dpram_addr(cpm_dpalloc(memsz, 8));
                dma_addr = 0;
        } else
                mem_addr = dma_alloc_coherent(NULL, memsz, &dma_addr,