if (!drv) {
_eglPreloadDrivers();
- drv = _eglOpenDriver(disp);
+ drv = _eglMatchDriver(disp);
if (!drv)
return _eglError(EGL_NOT_INITIALIZED, __FUNCTION__);
/* Initialize the particular display now */
- if (!drv->API.Initialize(drv, disp, &major_int, &minor_int)) {
- _eglCloseDriver(drv, disp);
+ if (!drv->API.Initialize(drv, disp, &major_int, &minor_int))
return _eglError(EGL_NOT_INITIALIZED, __FUNCTION__);
- }
disp->APImajor = major_int;
disp->APIminor = minor_int;
drv = disp->Driver;
if (drv) {
drv->API.Terminate(drv, disp);
- _eglCloseDriver(drv, disp);
disp->Driver = NULL;
}
*
* The matching is done by finding the driver with the highest score.
*/
-static _EGLDriver *
+_EGLDriver *
_eglMatchDriver(_EGLDisplay *dpy)
{
_EGLDriver *best_drv = NULL;
}
-/**
- * Open a preloaded driver.
- */
-_EGLDriver *
-_eglOpenDriver(_EGLDisplay *dpy)
-{
- _EGLDriver *drv = _eglMatchDriver(dpy);
- return drv;
-}
-
-
-/**
- * Close a preloaded driver.
- */
-EGLBoolean
-_eglCloseDriver(_EGLDriver *drv, _EGLDisplay *dpy)
-{
- return EGL_TRUE;
-}
-
-
/**
* Preload a user driver.
*
extern _EGLDriver *
-_eglOpenDriver(_EGLDisplay *dpy);
-
-
-extern EGLBoolean
-_eglCloseDriver(_EGLDriver *drv, _EGLDisplay *dpy);
+_eglMatchDriver(_EGLDisplay *dpy);
extern EGLBoolean