summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2021-08-28 06:03:26 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2021-08-28 06:03:26 +0000
commit63d1d60cdc7e3c94a503ec7f05a4d331ca46cbaf (patch)
tree376602718dd74fe81000a926b6b77e83881f9864 /sys
parentdc12423aa31fba2979376bf4fb8a277e2dd887f7 (diff)
Remove bogus code that tries to unmap GTT pages in a codepath that clearly
doesn't deal with non-GTT mappings. What the Linux code does here isn't possible on OpenBSD and probably unecessary. Seems to fix a crash reported by sthen@ ok jsg@
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pci/drm/i915/gem/i915_gem_mman.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/sys/dev/pci/drm/i915/gem/i915_gem_mman.c b/sys/dev/pci/drm/i915/gem/i915_gem_mman.c
index 8b5bb94a7ef..c326e2f9bd6 100644
--- a/sys/dev/pci/drm/i915/gem/i915_gem_mman.c
+++ b/sys/dev/pci/drm/i915/gem/i915_gem_mman.c
@@ -841,19 +841,6 @@ void i915_gem_object_release_mmap_offset(struct drm_i915_gem_object *obj)
#ifdef __linux__
drm_vma_node_unmap(&mmo->vma_node,
obj->base.dev->anon_inode->i_mapping);
-#else
- if (drm_mm_node_allocated(&mmo->vma_node.vm_node)) {
- struct drm_i915_private *dev_priv = obj->base.dev->dev_private;
- struct i915_vma *vma;
- struct vm_page *pg;
-
- for_each_ggtt_vma(vma, obj) {
- for (pg = &dev_priv->pgs[atop(vma->node.start)];
- pg != &dev_priv->pgs[atop(vma->node.start + vma->size)];
- pg++)
- pmap_page_protect(pg, PROT_NONE);
- }
- }
#endif
spin_lock(&obj->mmo.lock);
}