summaryrefslogtreecommitdiff
path: root/src/gallium/winsys/radeon
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/winsys/radeon')
-rw-r--r--src/gallium/winsys/radeon/drm/radeon_drm.c20
-rw-r--r--src/gallium/winsys/radeon/drm/radeon_drm.h7
-rw-r--r--src/gallium/winsys/radeon/drm/radeon_drm_public.h9
-rw-r--r--src/gallium/winsys/radeon/drm/radeon_r300.c2
4 files changed, 14 insertions, 24 deletions
diff --git a/src/gallium/winsys/radeon/drm/radeon_drm.c b/src/gallium/winsys/radeon/drm/radeon_drm.c
index a9ae09cb60..e9a276362f 100644
--- a/src/gallium/winsys/radeon/drm/radeon_drm.c
+++ b/src/gallium/winsys/radeon/drm/radeon_drm.c
@@ -32,12 +32,10 @@
#include "radeon_drm.h"
#include "radeon_r300.h"
#include "radeon_buffer.h"
+#include "radeon_drm_public.h"
#include "r300_winsys.h"
-#include "galahad/glhd_drm.h"
-#include "trace/tr_drm.h"
-
#include "util/u_memory.h"
#include "xf86drm.h"
@@ -155,7 +153,7 @@ static void do_ioctls(int fd, struct radeon_libdrm_winsys* winsys)
}
/* Create a pipe_screen. */
-struct pipe_screen* radeon_create_screen(struct drm_api* api, int drmFB)
+struct r300_winsys_screen* r300_drm_winsys_screen_create(int drmFB)
{
struct radeon_libdrm_winsys* rws;
boolean ret;
@@ -173,22 +171,10 @@ struct pipe_screen* radeon_create_screen(struct drm_api* api, int drmFB)
ret = radeon_setup_winsys(drmFB, rws);
if (ret == FALSE)
goto fail;
- return r300_create_screen(&rws->base);
+ return &rws->base;
}
fail:
FREE(rws);
return NULL;
}
-
-static struct drm_api radeon_drm_api_hooks = {
- .name = "radeon",
- .driver_name = "radeon",
- .create_screen = radeon_create_screen,
- .destroy = NULL,
-};
-
-struct drm_api* drm_api_create()
-{
- return galahad_drm_create(trace_drm_create(&radeon_drm_api_hooks));
-}
diff --git a/src/gallium/winsys/radeon/drm/radeon_drm.h b/src/gallium/winsys/radeon/drm/radeon_drm.h
index 3544c926d9..df6dd91ad5 100644
--- a/src/gallium/winsys/radeon/drm/radeon_drm.h
+++ b/src/gallium/winsys/radeon/drm/radeon_drm.h
@@ -30,12 +30,7 @@
#ifndef RADEON_DRM_H
#define RADEON_DRM_H
-#include "state_tracker/drm_api.h"
-
-
-struct pipe_screen* radeon_create_screen(struct drm_api* api, int drmFB);
-
-void radeon_destroy_drm_api(struct drm_api* api);
+#include "state_tracker/drm_driver.h"
/* Guess at whether this chipset should use r300g.
*
diff --git a/src/gallium/winsys/radeon/drm/radeon_drm_public.h b/src/gallium/winsys/radeon/drm/radeon_drm_public.h
new file mode 100644
index 0000000000..0d96ae8c47
--- /dev/null
+++ b/src/gallium/winsys/radeon/drm/radeon_drm_public.h
@@ -0,0 +1,9 @@
+
+#ifndef RADEON_DRM_PUBLIC_H
+#define RADEON_DRM_PUBLIC_H
+
+struct r300_winsys_screen;
+
+struct r300_winsys_screen *r300_drm_winsys_screen_create(int drmFD);
+
+#endif
diff --git a/src/gallium/winsys/radeon/drm/radeon_r300.c b/src/gallium/winsys/radeon/drm/radeon_r300.c
index d2d317dc20..cb26447606 100644
--- a/src/gallium/winsys/radeon/drm/radeon_r300.c
+++ b/src/gallium/winsys/radeon/drm/radeon_r300.c
@@ -25,7 +25,7 @@
#include "radeon_bo_gem.h"
#include "radeon_cs_gem.h"
-#include "state_tracker/drm_api.h"
+#include "state_tracker/drm_driver.h"
static struct r300_winsys_buffer *
radeon_r300_winsys_buffer_create(struct r300_winsys_screen *rws,