From: Eric Nelson Date: Thu, 25 Jul 2013 17:35:26 -0700 Subject: [U-Boot] [PATCH] video: mxc_ipuv3: fix memory alignment of framebuffer Message-ID: <1374798926-18743-1-git-send-email-eric.nelson@boundarydevices.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de The frame-buffer on i.MX boards needs to be aligned for DMA. Signed-off-by: Eric Nelson --- drivers/video/mxc_ipuv3_fb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/video/mxc_ipuv3_fb.c b/drivers/video/mxc_ipuv3_fb.c index ace226c..ad95831 100644 --- a/drivers/video/mxc_ipuv3_fb.c +++ b/drivers/video/mxc_ipuv3_fb.c @@ -416,7 +416,8 @@ static int mxcfb_map_video_memory(struct fb_info *fbi) fbi->fix.line_length; } - fbi->screen_base = (char *)malloc(fbi->fix.smem_len); + fbi->screen_base = (char *)memalign(ARCH_DMA_MINALIGN, + fbi->fix.smem_len); fbi->fix.smem_start = (unsigned long)fbi->screen_base; if (fbi->screen_base == 0) { puts("Unable to allocate framebuffer memory\n"); -- 1.8.1.2