summaryrefslogtreecommitdiff
path: root/bsd
diff options
context:
space:
mode:
Diffstat (limited to 'bsd')
-rw-r--r--bsd/Imakefile6
-rw-r--r--bsd/Makefile2
-rw-r--r--bsd/Makefile.bsd2
-rw-r--r--bsd/drm_context.h8
4 files changed, 16 insertions, 2 deletions
diff --git a/bsd/Imakefile b/bsd/Imakefile
index fddf8f53..034d5ff2 100644
--- a/bsd/Imakefile
+++ b/bsd/Imakefile
@@ -41,3 +41,9 @@ LinkSourceFile(radeon_drv.h,$(XF86OSSRC)/shared/drm/kernel)
LinkSourceFile(radeon_irq.c,$(XF86OSSRC)/shared/drm/kernel)
LinkSourceFile(radeon_mem.c,$(XF86OSSRC)/shared/drm/kernel)
LinkSourceFile(radeon_state.c,$(XF86OSSRC)/shared/drm/kernel)
+LinkSourceFile(sis.h,$(XF86OSSRC)/shared/drm/kernel)
+LinkSourceFile(sis_drm.h,$(XF86OSSRC)/shared/drm/kernel)
+LinkSourceFile(sis_drv.h,$(XF86OSSRC)/shared/drm/kernel)
+LinkSourceFile(sis_ds.c,$(XF86OSSRC)/shared/drm/kernel)
+LinkSourceFile(sis_ds.h,$(XF86OSSRC)/shared/drm/kernel)
+LinkSourceFile(sis_mm.c,$(XF86OSSRC)/shared/drm/kernel)
diff --git a/bsd/Makefile b/bsd/Makefile
index 04058648..3b678e19 100644
--- a/bsd/Makefile
+++ b/bsd/Makefile
@@ -1,4 +1,4 @@
# i810, i830 & sis are not complete
-SUBDIR = mga r128 radeon tdfx # i810 i830 sis gamma
+SUBDIR = mga r128 radeon tdfx sis # i810 i830 gamma
.include <bsd.subdir.mk>
diff --git a/bsd/Makefile.bsd b/bsd/Makefile.bsd
index 04058648..3b678e19 100644
--- a/bsd/Makefile.bsd
+++ b/bsd/Makefile.bsd
@@ -1,4 +1,4 @@
# i810, i830 & sis are not complete
-SUBDIR = mga r128 radeon tdfx # i810 i830 sis gamma
+SUBDIR = mga r128 radeon tdfx sis # i810 i830 gamma
.include <bsd.subdir.mk>
diff --git a/bsd/drm_context.h b/bsd/drm_context.h
index b4ec3bc3..a6116634 100644
--- a/bsd/drm_context.h
+++ b/bsd/drm_context.h
@@ -282,6 +282,11 @@ int DRM(addctx)( DRM_IOCTL_ARGS )
return DRM_ERR(ENOMEM);
}
+#ifdef DRIVER_CTX_CTOR
+ if ( ctx.handle != DRM_KERNEL_CONTEXT )
+ DRIVER_CTX_CTOR(ctx.handle); /* XXX: also pass dev ? */
+#endif
+
DRM_COPY_TO_USER_IOCTL( (drm_ctx_t *)data, ctx, sizeof(ctx) );
return 0;
@@ -340,6 +345,9 @@ int DRM(rmctx)( DRM_IOCTL_ARGS )
DRM_DEBUG( "%d\n", ctx.handle );
if ( ctx.handle != DRM_KERNEL_CONTEXT ) {
+#ifdef DRIVER_CTX_DTOR
+ DRIVER_CTX_DTOR(ctx.handle); /* XXX: also pass dev ? */
+#endif
DRM(ctxbitmap_free)( dev, ctx.handle );
}