X patch
This should do the right thing for the panel - you'll still have a virtual desktop if your specified size != the size of the panel, but it won't be all funky anymore.
J
src/amd_gx_driver.c +17 -9
@@ -807,6 +807,7 @@ GXSetVideoMode(ScrnInfoPtr pScrni, DisplayModePtr pMode) {GeodeRec *pGeode =GEODEPTR (pScrni);int flags =0 ; +int custom =0 ; pScrni->vtSema = TRUE;
@@ -817,14 +818,17 @@ GXSetVideoMode(ScrnInfoPtr pScrni, DisplayModePtr pMode)if (pMode->Flags &V_NVSYNC ) flags |=2 ; -/* XXX Question - why even use set_display_mode at all - shouldn't the -* mode timings be the same that we advertise? */ +/* Check to see if we should use custom or built-in timings */ -/* Only use the panel mode for built in modes */ +if (pMode->Panel) + custom = (pMode->type &M_T_USERDEF ); +else + custom = !(pMode->type & (M_T_BUILTIN |M_T_DEFAULT )); -if ((pMode->type &M_T_BUILTIN ) || (pMode->type &M_T_DEFAULT ) - && pGeode->Panel) { +/* If we're not doing a custom mode, then just set the fixed timings, +* otherwise, do the whole shooting match */ +if (!custom) {GFX (set_fixed_timings (pGeode->PanelX, pGeode->PanelY, pMode->CrtcHDisplay, pMode->CrtcVDisplay, pScrni->bitsPerPixel));
@@ -1430,11 +1434,16 @@ GXValidMode(int scrnIndex, DisplayModePtr pMode, Bool Verbose, int flags)ScrnInfoPtr pScrni = xf86Screens[scrnIndex];GeodeRec *pGeode =GEODEPTR (pScrni);int p, ret; +int custom =0 ; -/* Use the durango lookup for builtin or default modes only */ +if (pGeode->Panel) + custom = (pMode->type &M_T_USERDEF ); +else + custom = (pMode->type & (M_T_BUILTIN |M_T_DEFAULT )); -if ((pMode->type &M_T_BUILTIN ) || (pMode->type &M_T_DEFAULT )) { +/* Use the durango lookup for !custom modes */ +if (!custom) {if (pGeode->Panel) { if (pMode->CrtcHDisplay > pGeode->PanelX || pMode->CrtcVDisplay > pGeode->PanelY ||
@@ -1450,9 +1459,8 @@ GXValidMode(int scrnIndex, DisplayModePtr pMode, Bool Verbose, int flags) pMode->CrtcVDisplay, pScrni->bitsPerPixel, GeodeGetRefreshRate(pMode)); -if (ret <0 ) { +if (ret <0 )return MODE_BAD ; - } }if (pMode->Flags &V_INTERLACE )
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Linux-fbdev-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-fbdev-devel
Quoted 3 lines · Jordan Crouse
This should do the right thing for the panel - you'll still have a virtual desktop if your specified size != the size of the panel, but it won't be all funky anymore.
Sorry for that - that was the wrong address on the To line. Ignore me :)
Jordan
Signature · 9 lines
Jordan Crouse Systems Software Development Engineer Advanced Micro Devices, Inc. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/