summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2009-02-27 22:57:15 -0800
committerEric Anholt <eric@anholt.net>2009-03-06 13:26:10 -0800
commit755757669f0cad670cfa084d33d7c3e928d27855 (patch)
treefda74091fb49642d69b16b907b64da0e8ed5d004
parent917b20ead3cacf1e88314f20edde6a02b97b96d7 (diff)
Remove configured SW cursor support.
Any time we actually need SW cursors, it gets enabled automatically.
-rw-r--r--man/intel.man5
-rw-r--r--src/i830.h1
-rw-r--r--src/i830_driver.c37
-rw-r--r--src/i830_memory.c11
4 files changed, 16 insertions, 38 deletions
diff --git a/man/intel.man b/man/intel.man
index 01f15056..a8bf5798 100644
--- a/man/intel.man
+++ b/man/intel.man
@@ -59,11 +59,6 @@ are supported
.BI "Option \*qNoAccel\*q \*q" boolean \*q
Disable or enable acceleration. Default: acceleration is enabled.
.TP
-.BI "Option \*qSWCursor\*q \*q" boolean \*q
-Disable or enable software cursor. Default: software cursor is disable
-and a hardware cursor is used for configurations where the hardware cursor
-is available.
-.TP
.BI "Option \*qColorKey\*q \*q" integer \*q
This sets the default pixel value for the YUV video overlay key.
Default: undefined.
diff --git a/src/i830.h b/src/i830.h
index ffb2732d..2408ea98 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -497,7 +497,6 @@ typedef struct _I830Rec {
Bool fence_used[FENCE_NEW_NR];
accel_method_t accel;
- Bool SWCursor;
#ifdef I830_USE_XAA
XAAInfoRecPtr AccelInfoRec;
diff --git a/src/i830_driver.c b/src/i830_driver.c
index 908614ac..60a00768 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -302,7 +302,6 @@ static PciChipsets I830PciChipsets[] = {
typedef enum {
OPTION_ACCELMETHOD,
OPTION_NOACCEL,
- OPTION_SW_CURSOR,
OPTION_CACHE_LINES,
OPTION_DRI,
OPTION_XVIDEO,
@@ -325,7 +324,6 @@ typedef enum {
static OptionInfoRec I830Options[] = {
{OPTION_ACCELMETHOD, "AccelMethod", OPTV_ANYSTR, {0}, FALSE},
{OPTION_NOACCEL, "NoAccel", OPTV_BOOLEAN, {0}, FALSE},
- {OPTION_SW_CURSOR, "SWcursor", OPTV_BOOLEAN, {0}, FALSE},
{OPTION_CACHE_LINES, "CacheLines", OPTV_INTEGER, {0}, FALSE},
{OPTION_DRI, "DRI", OPTV_BOOLEAN, {0}, TRUE},
{OPTION_XVIDEO, "XVideo", OPTV_BOOLEAN, {0}, TRUE},
@@ -1503,6 +1501,10 @@ I830LoadSyms(ScrnInfoPtr pScrn)
return FALSE;
xf86LoaderReqSymLists(I810vgahwSymbols, NULL);
+ if (!xf86LoadSubModule(pScrn, "ramdac"))
+ return FALSE;
+ xf86LoaderReqSymLists(I810ramdacSymbols, NULL);
+
return TRUE;
}
@@ -1622,10 +1624,6 @@ I830AccelMethodInit(ScrnInfoPtr pScrn)
accel_name[pI830->accel]);
}
- if (xf86ReturnOptValBool(pI830->Options, OPTION_SW_CURSOR, FALSE)) {
- pI830->SWCursor = TRUE;
- }
-
pI830->directRenderingType = DRI_NONE;
if (!xf86ReturnOptValBool(pI830->Options, OPTION_DRI, TRUE))
pI830->directRenderingType = DRI_DISABLED;
@@ -1974,13 +1972,6 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
default:
break;
}
- if (!pI830->SWCursor) {
- if (!xf86LoadSubModule(pScrn, "ramdac")) {
- PreInitCleanup(pScrn);
- return FALSE;
- }
- xf86LoaderReqSymLists(I810ramdacSymbols, NULL);
- }
if (!pI830->use_drm_mode) {
i830CompareRegsToSnapshot(pScrn, "After PreInit");
@@ -3032,8 +3023,6 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
/* If DRI hasn't been explicitly disabled, try to initialize it.
* It will be used by the memory allocator.
*/
- if (pI830->directRenderingType == DRI_NONE && pI830->SWCursor)
- pI830->directRenderingType = DRI_DISABLED;
if (!pI830->can_resize && pI830->directRenderingType == DRI_NONE && I830DRIScreenInit(pScreen))
pI830->directRenderingType = DRI_XF86DRI;
@@ -3162,9 +3151,9 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
* InitGLXVisuals call back.
*/
if (pI830->directRenderingType == DRI_XF86DRI) {
- if (pI830->accel == ACCEL_NONE || pI830->SWCursor) {
+ if (pI830->accel == ACCEL_NONE) {
xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "DRI is disabled because it "
- "needs HW cursor and 2D accel.\n");
+ "needs 2D acceleration.\n");
pI830->directRenderingType = DRI_NONE;
}
}
@@ -3257,13 +3246,10 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
xf86SetSilkenMouse(pScreen);
miDCInitialize(pScreen, xf86GetPointerScreenFuncs());
- if (!pI830->SWCursor) {
- xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Initializing HW Cursor\n");
- if (!I830CursorInit(pScreen))
- xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
- "Hardware cursor initialization failed\n");
- } else
- xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Initializing SW Cursor!\n");
+ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Initializing HW Cursor\n");
+ if (!I830CursorInit(pScreen))
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Hardware cursor initialization failed\n");
#ifdef XF86DRI
/* Must be called before EnterVT, so we can acquire the DRI lock when
@@ -3571,8 +3557,7 @@ I830EnterVT(int scrnIndex, int flags)
i830_stop_ring(pScrn, FALSE);
i830_start_ring(pScrn);
}
- if (!pI830->SWCursor)
- I830InitHWCursor(pScrn);
+ I830InitHWCursor(pScrn);
/* Tell the BIOS that we're in control of mode setting now. */
i830_init_bios_control(pScrn);
diff --git a/src/i830_memory.c b/src/i830_memory.c
index 0fd5d5b9..84262af7 100644
--- a/src/i830_memory.c
+++ b/src/i830_memory.c
@@ -1448,11 +1448,10 @@ i830_allocate_2d_memory(ScrnInfoPtr pScrn)
i830_setup_fb_compression(pScrn);
/* Next, allocate other fixed-size allocations we have. */
- if (!pI830->SWCursor && !i830_allocate_cursor_buffers(pScrn)) {
- xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
- "Disabling HW cursor because the cursor memory "
- "allocation failed.\n");
- pI830->SWCursor = TRUE;
+ if (!i830_allocate_cursor_buffers(pScrn)) {
+ xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+ "Failed to allocate HW cursor space.\n");
+ return FALSE;
}
if (pI830->memory_manager == NULL) {
@@ -1997,7 +1996,7 @@ i830_bind_all_memory(ScrnInfoPtr pScrn)
FatalError("Couldn't bind memory for BO %s\n", mem->name);
}
}
- if (!pI830->SWCursor && !pI830->use_drm_mode)
+ if (!pI830->use_drm_mode)
i830_update_cursor_offsets(pScrn);
return TRUE;