diff options
author | Eamon Walsh <ewalsh@tycho.nsa.gov> | 2007-10-25 12:19:30 -0400 |
---|---|---|
committer | Eamon Walsh <ewalsh@moss-charon.epoch.ncsc.mil> | 2007-10-25 12:19:30 -0400 |
commit | b633d54b94d746d26e13014634d9f63bbb7e8f7d (patch) | |
tree | 4832d035672164284ff8698d5875e9d5435f494a /hw/xfree86/dri | |
parent | 4b05f19cb9e42d8c8eff5ca4e463f5bc2a05433d (diff) | |
parent | 48ca5961caee62f2980017a6bdc96a1b4c747727 (diff) |
Merge branch 'master' into XACE-SELINUX
Conflicts:
GL/glx/glxscreens.c
hw/xnest/Screen.c
render/glyph.c
render/glyphstr.h
render/render.c
Diffstat (limited to 'hw/xfree86/dri')
-rw-r--r-- | hw/xfree86/dri/dri.c | 40 | ||||
-rw-r--r-- | hw/xfree86/dri/xf86dri.c | 12 |
2 files changed, 5 insertions, 47 deletions
diff --git a/hw/xfree86/dri/dri.c b/hw/xfree86/dri/dri.c index c35386354..b736c6ae0 100644 --- a/hw/xfree86/dri/dri.c +++ b/hw/xfree86/dri/dri.c @@ -67,7 +67,6 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "dristruct.h" #include "xf86.h" #include "xf86drm.h" -#include "glxserver.h" #include "mi.h" #include "mipointer.h" #include "xf86_OSproc.h" @@ -953,24 +952,8 @@ static Bool DRICreateDummyContext(ScreenPtr pScreen, Bool needCtxPriv) { DRIScreenPrivPtr pDRIPriv = DRI_SCREEN_PRIV(pScreen); - __GLXscreen *pGLXScreen = glxGetScreen(pScreen); - __GLcontextModes *modes = pGLXScreen->modes; - void **pVisualConfigPriv = pGLXScreen->pVisualPriv; DRIContextPrivPtr pDRIContextPriv; void *contextStore; - VisualPtr visual; - int visNum; - - visual = pScreen->visuals; - - /* Find the X visual that corresponds the the first GLX visual */ - for (visNum = 0; - visNum < pScreen->numVisuals; - visNum++, visual++) { - if (modes->visualID == visual->vid) - break; - } - if (visNum == pScreen->numVisuals) return FALSE; if (!(pDRIContextPriv = DRICreateContextPriv(pScreen, @@ -980,9 +963,9 @@ DRICreateDummyContext(ScreenPtr pScreen, Bool needCtxPriv) contextStore = DRIGetContextStore(pDRIContextPriv); if (pDRIPriv->pDriverInfo->CreateContext && needCtxPriv) { - if (!pDRIPriv->pDriverInfo->CreateContext(pScreen, visual, + if (!pDRIPriv->pDriverInfo->CreateContext(pScreen, NULL, pDRIPriv->pSAREA->dummy_context, - *pVisualConfigPriv, + NULL, (DRIContextType)(long)contextStore)) { DRIDestroyContextPriv(pDRIContextPriv); return FALSE; @@ -1017,9 +1000,6 @@ DRICreateContext(ScreenPtr pScreen, VisualPtr visual, XID context, drm_context_t * pHWContext) { DRIScreenPrivPtr pDRIPriv = DRI_SCREEN_PRIV(pScreen); - __GLXscreen *pGLXScreen = glxGetScreen(pScreen); - __GLcontextModes *modes = pGLXScreen->modes; - void **pVisualConfigPriv = pGLXScreen->pVisualPriv; DRIContextPrivPtr pDRIContextPriv; void *contextStore; @@ -1031,26 +1011,14 @@ DRICreateContext(ScreenPtr pScreen, VisualPtr visual, } } - /* Find the GLX visual associated with the one requested */ - for (modes = pGLXScreen->modes; modes != NULL; modes = modes->next) { - if (modes->visualID == visual->vid) - break; - pVisualConfigPriv++; - } - - if (modes == NULL) { - /* No matching GLX visual found */ - return FALSE; - } - if (!(pDRIContextPriv = DRICreateContextPriv(pScreen, pHWContext, 0))) { return FALSE; } contextStore = DRIGetContextStore(pDRIContextPriv); if (pDRIPriv->pDriverInfo->CreateContext) { - if (!((*pDRIPriv->pDriverInfo->CreateContext)(pScreen, visual, - *pHWContext, *pVisualConfigPriv, + if (!((*pDRIPriv->pDriverInfo->CreateContext)(pScreen, NULL, + *pHWContext, NULL, (DRIContextType)(long)contextStore))) { DRIDestroyContextPriv(pDRIContextPriv); return FALSE; diff --git a/hw/xfree86/dri/xf86dri.c b/hw/xfree86/dri/xf86dri.c index c658421e8..e01d6d9be 100644 --- a/hw/xfree86/dri/xf86dri.c +++ b/hw/xfree86/dri/xf86dri.c @@ -373,19 +373,9 @@ ProcXF86DRICreateContext( rep.sequenceNumber = client->sequence; pScreen = screenInfo.screens[stuff->screen]; - visual = pScreen->visuals; - - /* Find the requested X visual */ - for (i = 0; i < pScreen->numVisuals; i++, visual++) - if (visual->vid == stuff->visual) - break; - if (i == pScreen->numVisuals) { - /* No visual found */ - return BadValue; - } if (!DRICreateContext( pScreen, - visual, + NULL, stuff->context, (drm_context_t *)&rep.hHWContext)) { return BadValue; |