summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/nouveau/nouveau_screen.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/dri/nouveau/nouveau_screen.c')
-rw-r--r--src/mesa/drivers/dri/nouveau/nouveau_screen.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/mesa/drivers/dri/nouveau/nouveau_screen.c b/src/mesa/drivers/dri/nouveau/nouveau_screen.c
index 424dfdc1993..7e51b94a2ff 100644
--- a/src/mesa/drivers/dri/nouveau/nouveau_screen.c
+++ b/src/mesa/drivers/dri/nouveau/nouveau_screen.c
@@ -28,7 +28,6 @@
#include "nouveau_context.h"
#include "nouveau_fbo.h"
#include "nouveau_texture.h"
-#include "nouveau_drmif.h"
#include "nv04_driver.h"
#include "nv10_driver.h"
#include "nv20_driver.h"
@@ -103,8 +102,7 @@ nouveau_init_screen2(__DRIscreen *dri_screen)
screen->dri_screen = dri_screen;
/* Open the DRM device. */
- ret = nouveau_device_open_existing(&screen->device, 0, dri_screen->fd,
- 0);
+ ret = nouveau_device_wrap(dri_screen->fd, 0, &screen->device);
if (ret) {
nouveau_error("Error opening the DRM device.\n");
goto fail;
@@ -144,8 +142,7 @@ nouveau_destroy_screen(__DRIscreen *dri_screen)
if (!screen)
return;
- if (screen->device)
- nouveau_device_close(&screen->device);
+ nouveau_device_del(&screen->device);
FREE(screen);
dri_screen->driverPrivate = NULL;