mirror of
https://github.com/X11Libre/xf86-video-r128.git
synced 2026-03-24 01:24:26 +00:00
Evaluate software cursor option inside R128PreInit
Since SWCursor option is referenced only once, it should be handled inside R128PreInit callback function rather than R128ScreenInit callback function. Signed-off-by: Kevin Brace <kevinbrace@gmx.com>
This commit is contained in:
@@ -349,6 +349,7 @@ typedef struct {
|
||||
int fifo_slots; /* Free slots in the FIFO (64 max) */
|
||||
int pix24bpp; /* Depth of pixmap for 24bpp framebuffer */
|
||||
Bool dac6bits; /* Use 6 bit DAC? */
|
||||
Bool swCursor;
|
||||
|
||||
/* Computed values for Rage 128 */
|
||||
int pitch;
|
||||
|
||||
@@ -1345,6 +1345,8 @@ Bool R128PreInit(ScrnInfoPtr pScrn, int flags)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
info->swCursor = FALSE;
|
||||
|
||||
/* By default, don't do VGA IOs on ppc */
|
||||
#if defined(__powerpc__) || defined(__sparc__) || !defined(WITH_VGAHW)
|
||||
info->VGAAccess = FALSE;
|
||||
@@ -1433,6 +1435,11 @@ Bool R128PreInit(ScrnInfoPtr pScrn, int flags)
|
||||
"Using framebuffer device\n");
|
||||
}
|
||||
|
||||
if (xf86ReturnOptValBool(info->Options,
|
||||
OPTION_SW_CURSOR, FALSE)) {
|
||||
info->swCursor = TRUE;
|
||||
}
|
||||
|
||||
/* Allocate an xf86CrtcConfig */
|
||||
xf86CrtcConfigInit(pScrn, &R128CRTCResizeFuncs);
|
||||
|
||||
@@ -2082,7 +2089,7 @@ Bool R128ScreenInit(SCREEN_INIT_ARGS_DECL)
|
||||
miDCInitialize(pScreen, xf86GetPointerScreenFuncs());
|
||||
|
||||
/* Hardware cursor setup */
|
||||
if (!xf86ReturnOptValBool(info->Options, OPTION_SW_CURSOR, FALSE)) {
|
||||
if (!info->swCursor) {
|
||||
if (R128CursorInit(pScreen)) {
|
||||
int width, height;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user