fix cursor reload bug
authorzyw <zyw@rock-chips.com>
Tue, 28 Jun 2011 07:43:00 +0000 (15:43 +0800)
committerzyw <zyw@rock-chips.com>
Tue, 28 Jun 2011 07:43:14 +0000 (15:43 +0800)
drivers/video/rk29_fb.c
drivers/video/rk29_fb.h

index 78589e1ac9fd9c70efc75c98b8a818b8bad47886..8322db4105570017e542316d741bbfe1cc3dbd70 100755 (executable)
@@ -38,6 +38,7 @@
 #include <asm/io.h>
 #include <asm/div64.h>
 #include <asm/uaccess.h>
+#include <asm/cacheflush.h>
 
 #include "rk29_fb.h"
 
@@ -794,20 +795,23 @@ int rk29_set_cursor_img_transform(char *data)
 
 int rk29_set_cursor_img(struct rk29fb_inf *inf, char *data)
 {
-       if(data)
-       {
-               rk29_set_cursor_img_transform(data);
+    if(data)
+    {
+        rk29_set_cursor_img_transform(data);
     }
-       else
-       {
-               rk29_set_cursor_img_transform(cursor_img);
-       }
-       LcdWrReg(inf, HWC_MST, __pa(rk29_cursor_buf));
-       LcdSetRegisterBit(inf, SYS_CONFIG,m_HWC_RELOAD_EN);
-       LcdWrReg(inf, REG_CFG_DONE, 0x01);
+    else
+    {
+        rk29_set_cursor_img_transform(cursor_img);
+    }
+    LcdWrReg(inf, HWC_MST, __pa(rk29_cursor_buf));
+    //LcdSetBit(inf, SYS_CONFIG,m_HWC_RELOAD_EN);
+    LcdSetBit(inf, SYS_CONFIG, m_HWC_RELOAD_EN |m_HWC_ENABLE);
+    flush_cache_all();
+    LcdWrReg(inf, REG_CFG_DONE, 0x01);
     return 0;
 }
 
+
 int rk29_set_cursor_test(struct fb_info *info)
 {
        struct rk29fb_inf *inf = dev_get_drvdata(info->device);
index 8811e07e9dd6f7689590298d4eee1eba9dbfccce..7bdea368997607fc3deec557f9f08d2908b2c417 100644 (file)
@@ -28,8 +28,8 @@
 #define OUT_S888            8
 #define OUT_S888DUMY        12
 #define OUT_P16BPP4         24  //Ä£Äⷽʽ,¿ØÖÆÆ÷²¢²»Ö§³Ö
-#define OUT_D888_P666       0x21  //666µÄÆÁ, ½ÓDATA2-7, DATA10-15, DATA17-22
-#define OUT_D888_P565       0x22  //565µÄÆÁ, ½ÓDATA3-7, DATA10-15, DATA18-22
+#define OUT_D888_P666       0x21  //666µÄÆÁ, ½ÓDATA2-7, DATA10-15, DATA18-23
+#define OUT_D888_P565       0x22  //565µÄÆÁ, ½ÓDATA3-7, DATA10-15, DATA19-23
 
 /* SYS_CONFIG */
 #define m_W2_FORMAT          (3<<0)