summaryrefslogtreecommitdiff
path: root/sys/dev/pci
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2020-10-13 05:03:04 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2020-10-13 05:03:04 +0000
commitb925557a7826c549cb0e948374f68b2098628219 (patch)
treee30b278431cacc492c60a2b8413e6d0b5fa2b585 /sys/dev/pci
parent7d2d48defa5eea5adad144680c48f1abb8afdd45 (diff)
move ifdef to make it clear we don't use __create_shmem()
Diffstat (limited to 'sys/dev/pci')
-rw-r--r--sys/dev/pci/drm/i915/gem/i915_gem_shmem.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/sys/dev/pci/drm/i915/gem/i915_gem_shmem.c b/sys/dev/pci/drm/i915/gem/i915_gem_shmem.c
index 537c92e5242..b61a1dbd24f 100644
--- a/sys/dev/pci/drm/i915/gem/i915_gem_shmem.c
+++ b/sys/dev/pci/drm/i915/gem/i915_gem_shmem.c
@@ -514,11 +514,11 @@ const struct drm_i915_gem_object_ops i915_gem_shmem_ops = {
.release = shmem_release,
};
+#ifdef __linux__
static int __create_shmem(struct drm_i915_private *i915,
struct drm_gem_object *obj,
resource_size_t size)
{
-#ifdef __linux__
unsigned long flags = VM_NORESERVE;
struct file *filp;
@@ -534,12 +534,8 @@ static int __create_shmem(struct drm_i915_private *i915,
obj->filp = filp;
return 0;
-#else
- drm_gem_private_object_init(&i915->drm, obj, size);
-
- return 0;
-#endif
}
+#endif
static struct drm_i915_gem_object *
create_shmem(struct intel_memory_region *mem,