From d8ec33fe0542141aed1d9016d2ecaf52da944b4b Mon Sep 17 00:00:00 2001 From: Adam Jackson Date: Wed, 10 Jan 2018 13:05:45 -0500 Subject: glx: Use vnd layer for dispatch (v4) The big change here is MakeCurrent and context tag tracking. We now delegate context tags entirely to the vnd layer, and simply store a pointer to the context state as the tag data. If a context is deleted while it's current, we allocate a fake ID for the context and move the context state there, so the tag data still points to a real context. As a result we can stop trying so hard to detach the client from contexts at disconnect time and just let resource destruction handle it. Since vnd handles all the MakeCurrent protocol now, our request handlers for it can just be return BadImplementation. We also remove a bunch of LEGAL_NEW_RESOURCE, because now by the time we're called vnd has already allocated its tracking resource on that XID. v2: Update to match v2 of the vnd import, and remove more redundant work like request length checks. v3: Add/remove the XID map from the vendor private thunk, not the backend. (Kyle Brenneman) v4: Fix deletion of ghost contexts (Kyle Brenneman) Signed-off-by: Adam Jackson --- include/glx_extinit.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/glx_extinit.h b/include/glx_extinit.h index 710ca6e3e..32b8fcf72 100644 --- a/include/glx_extinit.h +++ b/include/glx_extinit.h @@ -40,7 +40,10 @@ struct __GLXprovider { extern __GLXprovider __glXDRISWRastProvider; void GlxPushProvider(__GLXprovider * provider); - +Bool xorgGlxCreateVendor(void); +#else +static inline Bool xorgGlxCreateVendor(void) { return TRUE; } #endif + #endif -- cgit v1.2.3