aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAravind Iddamsetty <[email protected]>2023-02-03 19:22:05 +0530
committerTvrtko Ursulin <[email protected]>2023-02-06 09:49:07 +0000
commitbca0d1d3ceeb07be45a51c0fa4d57a0ce31b6aed (patch)
treeffd841ab5b5c022bf2bc4a7a8dd3d6c449f2551a
parent960dafa30455450d318756a9896a02727f2639e0 (diff)
drm/i915: Initialize the obj flags for shmem objects
Obj flags for shmem objects is not being set correctly. Fixes in setting BO_ALLOC_USER flag which applies to shmem objs as well. v2: Add fixes tag (Tvrtko, Matt A) Fixes: 13d29c823738 ("drm/i915/ehl: unconditionally flush the pages on acquire") Cc: <[email protected]> # v5.15+ Cc: Matthew Auld <[email protected]> Cc: Tvrtko Ursulin <[email protected]> Reviewed-by: Matthew Auld <[email protected]> Signed-off-by: Aravind Iddamsetty <[email protected]> Reviewed-by: Andrzej Hajda <[email protected]> Signed-off-by: Tvrtko Ursulin <[email protected]> [tursulin: Grouped all tags together.] Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
-rw-r--r--drivers/gpu/drm/i915/gem/i915_gem_shmem.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/gem/i915_gem_shmem.c b/drivers/gpu/drm/i915/gem/i915_gem_shmem.c
index 114443096841..37d1efcd3ca6 100644
--- a/drivers/gpu/drm/i915/gem/i915_gem_shmem.c
+++ b/drivers/gpu/drm/i915/gem/i915_gem_shmem.c
@@ -596,7 +596,7 @@ static int shmem_object_init(struct intel_memory_region *mem,
mapping_set_gfp_mask(mapping, mask);
GEM_BUG_ON(!(mapping_gfp_mask(mapping) & __GFP_RECLAIM));
- i915_gem_object_init(obj, &i915_gem_shmem_ops, &lock_class, 0);
+ i915_gem_object_init(obj, &i915_gem_shmem_ops, &lock_class, flags);
obj->mem_flags |= I915_BO_FLAG_STRUCT_PAGE;
obj->write_domain = I915_GEM_DOMAIN_CPU;
obj->read_domains = I915_GEM_DOMAIN_CPU;