summaryrefslogtreecommitdiffstats
path: root/sys/dev/drm
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2005-02-22 13:56:15 +0000
committerphk <phk@FreeBSD.org>2005-02-22 13:56:15 +0000
commit068a6e0ac25624950bd9de08432e300924290554 (patch)
treeb416e7e89912f15b529c69b1164b9cf524ca92fe /sys/dev/drm
parentaea571c6b579e2f62dd7d0fd464afe81ff4d4701 (diff)
downloadFreeBSD-src-068a6e0ac25624950bd9de08432e300924290554.zip
FreeBSD-src-068a6e0ac25624950bd9de08432e300924290554.tar.gz
Neuter DRM(mapbufs) until somebody finds time to try to fix it.
It is _never_ OK to find a vnode from a struct cdev because you have no way of telling if you get the right one. You might be in jail or chroot for instance.
Diffstat (limited to 'sys/dev/drm')
-rw-r--r--sys/dev/drm/drm_bufs.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/dev/drm/drm_bufs.h b/sys/dev/drm/drm_bufs.h
index 841fb13..6f7f205 100644
--- a/sys/dev/drm/drm_bufs.h
+++ b/sys/dev/drm/drm_bufs.h
@@ -923,8 +923,12 @@ int DRM(mapbufs)( DRM_IOCTL_ARGS )
#ifdef __FreeBSD__
vaddr = round_page((vm_offset_t)vms->vm_daddr + MAXDSIZ);
+#ifdef this_is_just_plain_bogus
retcode = vm_mmap(&vms->vm_map, &vaddr, size, PROT_READ | PROT_WRITE,
VM_PROT_ALL, MAP_SHARED, SLIST_FIRST(&kdev->si_hlist), foff );
+#else
+ retcode = EOPNOTSUPP;
+#endif
#elif defined(__NetBSD__)
vaddr = round_page((vaddr_t)vms->vm_daddr + MAXDSIZ);
retcode = uvm_mmap(&vms->vm_map, &vaddr, size,
OpenPOWER on IntegriCloud