From 0eaa02c836821556c1e8d0141f49f57e23f2548d Mon Sep 17 00:00:00 2001 From: Chia-I Wu Date: Thu, 13 Aug 2009 13:01:48 +0800 Subject: egl: Change the way drivers are loaded. Driver is chosen and preloaded when eglGetDisplay is called. Later when eglInitialize is called, the same driver is matched to initialize the display. Also, add new, but unused, hooks to EGLDriver to allow a driver to probe a display or unload itself. Signed-off-by: Chia-I Wu --- src/egl/main/egldisplay.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'src/egl/main/egldisplay.c') diff --git a/src/egl/main/egldisplay.c b/src/egl/main/egldisplay.c index c684e4291e..ba7e634c9d 100644 --- a/src/egl/main/egldisplay.c +++ b/src/egl/main/egldisplay.c @@ -94,7 +94,7 @@ _eglNewDisplay(NativeDisplayType nativeDisplay) _eglInitDisplay(); dpy->SurfaceHash = _eglSurfaceHash; - dpy->DriverName = _eglChooseDriver(dpy); + dpy->DriverName = _eglPreloadDriver(dpy); if (!dpy->DriverName) { free(dpy); return NULL; @@ -244,11 +244,6 @@ _eglCleanupDisplay(_EGLDisplay *disp) disp->Configs = NULL; /* XXX incomplete */ - - free((void *) disp->DriverName); - disp->DriverName = NULL; - - /* driver deletes the _EGLDisplay object */ } -- cgit v1.2.3