add cursor_enable option to enable hw cursor 30/32230/1
authorBoram Park <boram1288.park@samsung.com>
Wed, 17 Dec 2014 04:24:09 +0000 (13:24 +0900)
committerBoram Park <boram1288.park@samsung.com>
Wed, 17 Dec 2014 04:24:25 +0000 (13:24 +0900)
Change-Id: Icf0a6bfa07b52aefd20ba1acb8cf212df609f6bc

src/sec.c

index ecd454a..6173653 100644 (file)
--- a/src/sec.c
+++ b/src/sec.c
@@ -115,6 +115,7 @@ typedef enum
     OPTION_PRESENT,
     OPTION_DRI3,
     OPTION_PARTIAL_UPDATE,
+    OPTION_CURSOR_ENABLE,
 } SECOpts;
 
 static const OptionInfoRec SECOptions[] =
@@ -134,6 +135,7 @@ static const OptionInfoRec SECOptions[] =
     { OPTION_PRESENT,  "present",    OPTV_BOOLEAN, {0}, FALSE },
     { OPTION_DRI3,        "dri3",       OPTV_BOOLEAN, {0}, FALSE },
     { OPTION_PARTIAL_UPDATE,  "partial_update",    OPTV_BOOLEAN, {0}, FALSE },
+    { OPTION_CURSOR_ENABLE,  "cursor_enable",    OPTV_BOOLEAN, {0}, FALSE },
     { -1,              NULL,         OPTV_NONE,    {0}, FALSE }
 };
 
@@ -594,6 +596,16 @@ _checkDriverOptions (ScrnInfoPtr pScrn)
             xf86DrvMsg (pScrn->scrnIndex, X_CONFIG, "Use partial update.\n");
         }
     }
+
+    /* cursor_enable */
+    if (xf86ReturnOptValBool (pSec->Options, OPTION_CURSOR_ENABLE, FALSE))
+    {
+        if (xf86ReturnOptValBool (pSec->Options, OPTION_CURSOR_ENABLE, FALSE))
+        {
+            pSec->enableCursor = TRUE;
+            xf86DrvMsg (pScrn->scrnIndex, X_CONFIG, "Enable hw cursor.\n");
+        }
+    }
 }
 
 #if HAVE_UDEV