summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/target-helpers/drm_helper.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/auxiliary/target-helpers/drm_helper.h')
-rw-r--r--src/gallium/auxiliary/target-helpers/drm_helper.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/target-helpers/drm_helper.h b/src/gallium/auxiliary/target-helpers/drm_helper.h
index 90820d3fe91..e056c58ba96 100644
--- a/src/gallium/auxiliary/target-helpers/drm_helper.h
+++ b/src/gallium/auxiliary/target-helpers/drm_helper.h
@@ -266,5 +266,27 @@ pipe_vc4_create_screen(int fd)
#endif
+#ifdef GALLIUM_ETNAVIV
+#include "etnaviv/drm/etnaviv_drm_public.h"
+
+struct pipe_screen *
+pipe_etna_create_screen(int fd)
+{
+ struct pipe_screen *screen;
+
+ screen = etna_drm_screen_create(fd);
+ return screen ? debug_screen_wrap(screen) : NULL;
+}
+
+#else
+
+struct pipe_screen *
+pipe_etna_create_screen(int fd)
+{
+ fprintf(stderr, "etnaviv: driver missing\n");
+ return NULL;
+}
+
+#endif
#endif /* DRM_HELPER_H */