Re: [RFC 1/2] drm/i915: Refactor PAT/object cache handling

2023-07-14 Thread Tvrtko Ursulin
On 14/07/2023 06:36, Yang, Fei wrote: [snip] @@ -326,10 +330,10 @@ int i915_gem_get_caching_ioctl(struct drm_device *dev, void *data, goto out; } - if (i915_gem_object_has_cache_level(obj, I915_CACHE_LLC) || - i915_gem_object_has_cache_level(obj, I915_CACHE_

RE: [RFC 1/2] drm/i915: Refactor PAT/object cache handling

2023-07-13 Thread Yang, Fei
[snip] > @@ -326,10 +330,10 @@ int i915_gem_get_caching_ioctl(struct drm_device *dev, > void *data, > goto out; > } > > - if (i915_gem_object_has_cache_level(obj, I915_CACHE_LLC) || > - i915_gem_object_has_cache_level(obj, I915_CACHE_L3_LLC)) > + if (i915_gem_ob

[RFC 1/2] drm/i915: Refactor PAT/object cache handling

2023-07-13 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Commit 9275277d5324 ("drm/i915: use pat_index instead of cache_level") has introduced PAT indices to i915 internal APIs, partially replacing the usage of driver internal cache_level, but has also added a few questionable design decisions which this patch tries to improve upon