Created attachment 27273 [details] [review] Patch which (incorrectly) removes the problematic calls to __glXExtensionBitIsEnabled() I'm using a Cygwin/X X server (which I'm writing some code for), which announces GLX version 1.2 and the GLX_SGIX_fbconfig extension Indirect rendering is forced for the client using LIBGL_ALWAYS_INDIRECT glxgears_fbconfig demo fails due to glXCreateContextWithConfigSGIX failing. The cause of this seems to be that the mesa implementation of glXGetFBConfigFromVisualSGIX() uses __glXExtensionBitIsEnabled() to check if the GLX_SGIX_fbconfig extension is available, but that function only checks if the extension is supported for direct rendering. Nothing else apart from these 3 functions from GLX_SGIX_fbconfig seems to use __glXExtensionBitIsEnabled, so I'm not sure exactly what the bug is here, or what the solution is. Attached is a patch which removes those checks, and allows glxgears_fbconfig to run successfully, but that's probably incorrect for the direct path.
Created attachment 27364 [details] [review] Patch to move initialization of ext_list_first_time out of DRI driver After a bit more staring at the code, the attached patch may be a more correct way to fix this: ext_list_first_time is only set in the DRI driver loader CreateScreen routine at the moment, so never gets set if DRI drivers are disabled by setting LIBGL_ALWAYS_INDIRECT. If ext_list_first_time isn't set, the screen's direct_support flags (which seems to be a bit misnamed as it actually reflects the extensions supported by the client/server combination when direct rendering isn't available) are never intialized, so when __glXExtensionBitIsEnabled() is used to check them, they are always false. So, this patch moves the initialization of ext_list_first_time out of the DRI driver loaders and up to where the screen config is allocated and initalized.
Created attachment 29975 [details] [review] Patch to move initialization of ext_list_first_time out of DRI driver Refreshed patch for git master
Retitled the bug to reflect the more correct analysis of what's wrong in comment #1
Created attachment 33793 [details] [review] Patch to move initialization of ext_list_first_time to where it's storage is allocated Refreshed patch for git master
Committed. Thanks.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.