From cb5aaa89871c051098ae8067d0e386840b7bdc59 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Sat, 6 Nov 2004 23:02:07 +0000 Subject: 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. --- shared-core/sis_mm.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'shared-core/sis_mm.c') 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 -- cgit v1.2.3