summaryrefslogtreecommitdiffstats
path: root/src/gallium/targets/dri-nouveau
diff options
context:
space:
mode:
authorJakob Bornecrantz <[email protected]>2010-06-23 23:03:28 +0200
committerJakob Bornecrantz <[email protected]>2010-06-23 23:15:07 +0200
commitcf91accc93b9f172b2f7c970f39e69b268a5bb26 (patch)
treeb8eb030cea7d76b0a26a20cc8a35415991aacbe5 /src/gallium/targets/dri-nouveau
parent10e3b9f4d029df5c6c01a5d76c9085c48d82ac43 (diff)
nouveau: Move bootstrap code to targets
Well sorta, at least I removed the drm_api dependancy and the target can layer anything it wants to now.
Diffstat (limited to 'src/gallium/targets/dri-nouveau')
-rw-r--r--src/gallium/targets/dri-nouveau/target.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/gallium/targets/dri-nouveau/target.c b/src/gallium/targets/dri-nouveau/target.c
index e16e86cd3d8..ca3ec53029a 100644
--- a/src/gallium/targets/dri-nouveau/target.c
+++ b/src/gallium/targets/dri-nouveau/target.c
@@ -1,4 +1,17 @@
-#include "target-helpers/drm_api_compat.h"
+#include "state_tracker/drm_driver.h"
+#include "nouveau/drm/nouveau_drm_public.h"
-DRM_API_COMPAT_STRUCT("nouveau", "nouveau")
+static struct pipe_screen *
+create_screen(int fd)
+{
+ struct pipe_screen *screen;
+
+ screen = nouveau_drm_screen_create(fd);
+ if (!screen)
+ return NULL;
+
+ return screen;
+}
+
+DRM_DRIVER_DESCRIPTOR("nouveau", "nouveau", create_screen)