summaryrefslogtreecommitdiff
path: root/src/gallium/state_trackers/dri/dri_context.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/state_trackers/dri/dri_context.c')
-rw-r--r--src/gallium/state_trackers/dri/dri_context.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/src/gallium/state_trackers/dri/dri_context.c b/src/gallium/state_trackers/dri/dri_context.c
index 45eaec4ed3..8819936fca 100644
--- a/src/gallium/state_trackers/dri/dri_context.c
+++ b/src/gallium/state_trackers/dri/dri_context.c
@@ -69,7 +69,7 @@ dri_create_context(const __GLcontextModes * visual,
driParseConfigFiles(&ctx->optionCache,
&screen->optionCache, sPriv->myNum, "dri");
- ctx->pipe = drm_api_hooks.create_context(screen->pipe_screen);
+ ctx->pipe = screen->api->create_context(screen->api, screen->pipe_screen);
if (ctx->pipe == NULL)
goto fail;
@@ -100,7 +100,6 @@ void
dri_destroy_context(__DRIcontextPrivate * cPriv)
{
struct dri_context *ctx = dri_context(cPriv);
- struct dri_screen *screen = dri_screen(cPriv->driScreenPriv);
/* No particular reason to wait for command completion before
* destroying a context, but it is probably worthwhile flushing it
@@ -109,9 +108,6 @@ dri_destroy_context(__DRIcontextPrivate * cPriv)
*/
st_flush(ctx->st, 0, NULL);
- if (screen->dummyContext == ctx)
- screen->dummyContext = NULL;
-
/* Also frees ctx->pipe?
*/
st_destroy_context(ctx->st);
@@ -143,7 +139,6 @@ dri_make_current(__DRIcontextPrivate * cPriv,
{
if (cPriv) {
struct dri_context *ctx = dri_context(cPriv);
- struct dri_screen *screen = dri_screen(cPriv->driScreenPriv);
struct dri_drawable *draw = dri_drawable(driDrawPriv);
struct dri_drawable *read = dri_drawable(driReadPriv);
struct st_context *old_st = st_get_current();
@@ -153,11 +148,6 @@ dri_make_current(__DRIcontextPrivate * cPriv,
++ctx->bind_count;
- /* This is for situations in which we need a rendering context but
- * there may not be any currently bound.
- */
- screen->dummyContext = ctx;
-
if (ctx->dPriv != driDrawPriv) {
ctx->dPriv = driDrawPriv;
ctx->d_stamp = driDrawPriv->lastStamp - 1;