When allocate framebuffer memory using dma_alloc_coherent(),
we'd better use dma_addr_t instead of phys_addr_t. Because the
address we got in fact is DMA or bus address for the platform.
This patch also fixes below build warning:
drivers/video/fbdev/ocfb.c:335:2:
warning: passing argument 3 of ‘dma_alloc_attrs’
from incompatible pointer type [enabled by default]
Signed-off-by: Qiang Chen <redacted>
---
drivers/video/fbdev/ocfb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
@@ -61,7 +61,7 @@ struct ocfb_dev {/* flag indicating whether the regs are little endian accessed */intlittle_endian;/* Physical and virtual addresses of framebuffer */-phys_addr_tfb_phys;+dma_addr_tfb_phys;void__iomem*fb_virt;u32pseudo_palette[PALETTE_SIZE];};
From: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> Date: 2014-12-07 06:17:34
On Fri, Dec 05, 2014 at 04:18:30PM +0800, Qiang Chen wrote:
When allocate framebuffer memory using dma_alloc_coherent(),
we'd better use dma_addr_t instead of phys_addr_t. Because the
address we got in fact is DMA or bus address for the platform.
This patch also fixes below build warning:
drivers/video/fbdev/ocfb.c:335:2:
warning: passing argument 3 of ‘dma_alloc_attrs’
from incompatible pointer type [enabled by default]
Signed-off-by: Qiang Chen <redacted>
Acked-by: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
From: Tomi Valkeinen <hidden> Date: 2015-01-13 10:49:53
On 05/12/14 10:18, Qiang Chen wrote:
quoted hunk
When allocate framebuffer memory using dma_alloc_coherent(),
we'd better use dma_addr_t instead of phys_addr_t. Because the
address we got in fact is DMA or bus address for the platform.
This patch also fixes below build warning:
drivers/video/fbdev/ocfb.c:335:2:
warning: passing argument 3 of ‘dma_alloc_attrs’
from incompatible pointer type [enabled by default]
Signed-off-by: Qiang Chen <redacted>
---
drivers/video/fbdev/ocfb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
@@ -61,7 +61,7 @@ struct ocfb_dev {/* flag indicating whether the regs are little endian accessed */intlittle_endian;/* Physical and virtual addresses of framebuffer */-phys_addr_tfb_phys;+dma_addr_tfb_phys;void__iomem*fb_virt;u32pseudo_palette[PALETTE_SIZE];};