diff mbox

sh: LCDC dcache flush for deferred io

Message ID 20090701050405.2252.48329.sendpatchset@rx1.opensource.se (mailing list archive)
State Superseded
Headers show

Commit Message

Magnus Damm July 1, 2009, 5:04 a.m. UTC
From: Magnus Damm <damm@igel.co.jp>

Since writenotify on uncached vmas is unsupported in 2.6.31,
live with cached framebuffer memory in the deferred io
case for now and flush the dcache before forcing refresh.

Signed-off-by: Magnus Damm <damm@igel.co.jp>
---

 Suitable for 2.6.31.

 drivers/video/sh_mobile_lcdcfb.c |    6 ++++++
 1 file changed, 6 insertions(+)

--
To unsubscribe from this list: send the line "unsubscribe linux-sh" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

--- 0001/drivers/video/sh_mobile_lcdcfb.c
+++ work/drivers/video/sh_mobile_lcdcfb.c	2009-07-01 13:26:36.000000000 +0900
@@ -211,6 +211,12 @@  static void sh_mobile_lcdc_deferred_io(s
 {
 	struct sh_mobile_lcdc_chan *ch = info->par;
 
+	/* framebuffer memory is cached if deferred io is enabled.
+	 * the LCDC is located behind the caches so we must flush the
+	 * dcache before forcing a LCD refresh.
+	 */
+	flush_dcache_all();
+
 	/* enable clocks before accessing hardware */
 	sh_mobile_lcdc_clk_on(ch->lcdc);