summaryrefslogtreecommitdiff
path: root/shared-core/sis_mm.c
diff options
context:
space:
mode:
authorEric Anholt <anholt@freebsd.org>2004-11-06 23:02:07 +0000
committerEric Anholt <anholt@freebsd.org>2004-11-06 23:02:07 +0000
commitcb5aaa89871c051098ae8067d0e386840b7bdc59 (patch)
tree240423a7c804efe8c9d4c6fdde2b40b9e7eb15fa /shared-core/sis_mm.c
parent7ddbd38dde5dc5566ba14f2b1c449611a6d0224f (diff)
Convert more drivers for bsd-core, moving the ioctl definitions to shared
code. Remove the "drv" from sisdrv, as it's unnecessary. Use the drm_pci functions in i915 instead of per-os implementations of the same. Avoid whitespace within fields in drm_pciids.txt (one of the r300 definitions), since it breaks the bsd pciids script. Tested on sis, mga, r128. i915 needs more work.
Diffstat (limited to 'shared-core/sis_mm.c')
-rw-r--r--shared-core/sis_mm.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/shared-core/sis_mm.c b/shared-core/sis_mm.c
index 7b0a2a43..497f2026 100644
--- a/shared-core/sis_mm.c
+++ b/shared-core/sis_mm.c
@@ -40,6 +40,17 @@
#include "sis_drv.h"
#include "sis_ds.h"
+drm_ioctl_desc_t sis_ioctls[] = {
+ [DRM_IOCTL_NR(DRM_SIS_FB_ALLOC)] = {sis_fb_alloc, 1, 0},
+ [DRM_IOCTL_NR(DRM_SIS_FB_FREE)] = {sis_fb_free, 1, 0},
+ [DRM_IOCTL_NR(DRM_SIS_AGP_INIT)] = {sis_ioctl_agp_init, 1, 1},
+ [DRM_IOCTL_NR(DRM_SIS_AGP_ALLOC)] = {sis_ioctl_agp_alloc, 1, 0},
+ [DRM_IOCTL_NR(DRM_SIS_AGP_FREE)] = {sis_ioctl_agp_free, 1, 0},
+ [DRM_IOCTL_NR(DRM_SIS_FB_INIT)] = {sis_fb_init, 1, 1}
+};
+
+int sis_max_ioctl = DRM_ARRAY_SIZE(sis_ioctls);
+
#define MAX_CONTEXT 100
#define VIDEO_TYPE 0
#define AGP_TYPE 1