]> git.karo-electronics.de Git - linux-beck.git/commitdiff
video: ocfb: Fix data type warning
authorQiang Chen <qiang2.chen@sonymobile.com>
Fri, 5 Dec 2014 08:18:30 +0000 (16:18 +0800)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Tue, 13 Jan 2015 10:53:25 +0000 (12:53 +0200)
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 <qiang2.chen@sonymobile.com>
Acked-by: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
drivers/video/fbdev/ocfb.c

index 7f9dc9bec3099b98984bd1533f5f57abe56d30f9..de9819660ca09ea17e52cf1f259f001adc30ac56 100644 (file)
@@ -61,7 +61,7 @@ struct ocfb_dev {
        /* flag indicating whether the regs are little endian accessed */
        int little_endian;
        /* Physical and virtual addresses of framebuffer */
-       phys_addr_t fb_phys;
+       dma_addr_t fb_phys;
        void __iomem *fb_virt;
        u32 pseudo_palette[PALETTE_SIZE];
 };