[PATCH 12/15] xf86: migrate SetDGAMode from index to ScrnInfoPtr (ABI/API)

Alan Coopersmith alan.coopersmith at oracle.com
Tue Apr 10 09:20:08 PDT 2012


On 04/10/12 07:47 AM, Dave Airlie wrote:
> This migrates the SetDGAMode callback from an index to ScrnInfoPtr.
> 
> Signed-off-by: Dave Airlie <airlied at redhat.com>
> ---
>  hw/xfree86/common/xf86DGA.c  |   10 ++++------
>  hw/xfree86/common/xf86cmap.c |   12 ++++++------
>  hw/xfree86/common/xf86str.h  |    2 +-
>  hw/xfree86/xaa/xaaInit.c     |    8 ++++----
>  hw/xfree86/xaa/xaalocal.h    |    2 +-
>  5 files changed, 16 insertions(+), 18 deletions(-)

hw/xfree86/common/xf86DGA.c also stores the pScrn pointer in it's
private rec, and a lot of functions do basically:

    DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]);
    pScrn = pScreenPriv->pScrn;

Should pScrn be removed from the privates and all those be replaced with
passing pointers instead of indexes or xf86ScrnToScreen() calls?

Or are we okay with ignoring the inconsistency while waiting for DGA to die
as long promised?

-- 
	-Alan Coopersmith-              alan.coopersmith at oracle.com
	 Oracle Solaris Engineering - http://blogs.oracle.com/alanc


More information about the xorg-devel mailing list