From ecec3b3e080464cc1b4e792cf4d8e7e89d50b011 Mon Sep 17 00:00:00 2001 From: Russell King Date: Wed, 3 Sep 2008 17:33:51 -0700 Subject: [PATCH] Fix McBSP virt_base usage As discussed on linux-omap list. This patch is already in Russell's queue for 2.6.27 -rc series. Signed-off-by: Tony Lindgren --- arch/arm/mach-omap1/mcbsp.c | 8 ++++---- arch/arm/plat-omap/mcbsp.c | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/arm/mach-omap1/mcbsp.c b/arch/arm/mach-omap1/mcbsp.c index 265cfc2c490..e4fe1c77331 100644 --- a/arch/arm/mach-omap1/mcbsp.c +++ b/arch/arm/mach-omap1/mcbsp.c @@ -159,7 +159,7 @@ static struct omap_mcbsp_platform_data omap730_mcbsp_pdata[] = { #ifdef CONFIG_ARCH_OMAP15XX static struct omap_mcbsp_platform_data omap15xx_mcbsp_pdata[] = { { - .virt_base = OMAP1510_MCBSP1_BASE, + .virt_base = io_p2v(OMAP1510_MCBSP1_BASE), .dma_rx_sync = OMAP_DMA_MCBSP1_RX, .dma_tx_sync = OMAP_DMA_MCBSP1_TX, .rx_irq = INT_McBSP1RX, @@ -176,7 +176,7 @@ static struct omap_mcbsp_platform_data omap15xx_mcbsp_pdata[] = { .ops = &omap1_mcbsp_ops, }, { - .virt_base = OMAP1510_MCBSP3_BASE, + .virt_base = io_p2v(OMAP1510_MCBSP3_BASE), .dma_rx_sync = OMAP_DMA_MCBSP3_RX, .dma_tx_sync = OMAP_DMA_MCBSP3_TX, .rx_irq = INT_McBSP3RX, @@ -194,7 +194,7 @@ static struct omap_mcbsp_platform_data omap15xx_mcbsp_pdata[] = { #ifdef CONFIG_ARCH_OMAP16XX static struct omap_mcbsp_platform_data omap16xx_mcbsp_pdata[] = { { - .virt_base = OMAP1610_MCBSP1_BASE, + .virt_base = io_p2v(OMAP1610_MCBSP1_BASE), .dma_rx_sync = OMAP_DMA_MCBSP1_RX, .dma_tx_sync = OMAP_DMA_MCBSP1_TX, .rx_irq = INT_McBSP1RX, @@ -211,7 +211,7 @@ static struct omap_mcbsp_platform_data omap16xx_mcbsp_pdata[] = { .ops = &omap1_mcbsp_ops, }, { - .virt_base = OMAP1610_MCBSP3_BASE, + .virt_base = io_p2v(OMAP1610_MCBSP3_BASE), .dma_rx_sync = OMAP_DMA_MCBSP3_RX, .dma_tx_sync = OMAP_DMA_MCBSP3_TX, .rx_irq = INT_McBSP3RX, diff --git a/arch/arm/plat-omap/mcbsp.c b/arch/arm/plat-omap/mcbsp.c index 0f0e3f3cd2a..8dbded5cc11 100644 --- a/arch/arm/plat-omap/mcbsp.c +++ b/arch/arm/plat-omap/mcbsp.c @@ -701,7 +701,7 @@ int omap_mcbsp_xmit_buffer(unsigned int id, dma_addr_t buffer, omap_set_dma_dest_params(mcbsp->dma_tx_lch, src_port, OMAP_DMA_AMODE_CONSTANT, - mcbsp->io_base + OMAP_MCBSP_REG_DXR1, + io_v2p(mcbsp->io_base + OMAP_MCBSP_REG_DXR1), 0, 0); omap_set_dma_src_params(mcbsp->dma_tx_lch, @@ -764,7 +764,7 @@ int omap_mcbsp_recv_buffer(unsigned int id, dma_addr_t buffer, omap_set_dma_src_params(mcbsp->dma_rx_lch, src_port, OMAP_DMA_AMODE_CONSTANT, - mcbsp->io_base + OMAP_MCBSP_REG_DRR1, + io_v2p(mcbsp->io_base + OMAP_MCBSP_REG_DRR1), 0, 0); omap_set_dma_dest_params(mcbsp->dma_rx_lch, -- 2.41.1