Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Iddamsetty, Aravind" <aravind.iddamsetty@intel.com>
To: Matthew Auld <matthew.auld@intel.com>, <intel-gfx@lists.freedesktop.org>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH] Initialize the obj flags for shmem objects
Date: Fri, 3 Feb 2023 18:29:26 +0530	[thread overview]
Message-ID: <39b909c1-42dc-b762-7af6-a66fc6732f56@intel.com> (raw)
In-Reply-To: <f0dc490d-756a-d0fe-a519-3730be0707d2@intel.com>



On 03-02-2023 17:42, Matthew Auld wrote:
> On 03/02/2023 11:57, Aravind Iddamsetty wrote:
>> Obj flags for shmem objects is not being set correctly.
>>
>> Cc: Matthew Auld <matthew.auld@intel.com>
>> Signed-off-by: Aravind Iddamsetty <aravind.iddamsetty@intel.com>
> 
> Subject should have "drm/i915:" prefix.
My bad missed that.
> 
> This is also a bug fix due to not setting BO_ALLOC_USER (the other flags
> don't seem to matter for shmem), which is quite important, so we need to
> figure out the "Fixes" tag. Maybe mention in the commit message that
> this fixes setting ALLOC_USER which is needed even for shmem.
> 
> Looking at the git history, ALLOC_USER looks to be first introduced in
> 213d50927763 ("drm/i915/ttm: Introduce a TTM i915 gem object backend"),
> but the users of ALLOC_USER at this stage are only interesting for the
> ttm backend, and that already passes the flags due to using its own
> object_init() vfunc for all normal object types.
> 
> So the first real user impacted by this bug appears to be in:
> 13d29c823738 ("drm/i915/ehl: unconditionally flush the pages on acquire").
> 
> So I think needs:
> 
> Fixes: 13d29c823738 ("drm/i915/ehl: unconditionally flush the pages on
> acquire")
> Cc: <stable@vger.kernel.org> # v5.15+
> 
> With that,
> Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Thank you will resend the patch.

Regards,
Aravind.
> 
> 
>> ---
>>   drivers/gpu/drm/i915/gem/i915_gem_shmem.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> 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;

  reply	other threads:[~2023-02-03 12:59 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-03 11:57 [Intel-gfx] [PATCH] Initialize the obj flags for shmem objects Aravind Iddamsetty
2023-02-03 12:10 ` Tvrtko Ursulin
2023-02-03 12:12   ` Matthew Auld
2023-02-03 13:00   ` Iddamsetty, Aravind
2023-02-03 12:12 ` Matthew Auld
2023-02-03 12:59   ` Iddamsetty, Aravind [this message]
2023-02-03 15:27 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
2023-02-03 15:50 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-02-04 20:28 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=39b909c1-42dc-b762-7af6-a66fc6732f56@intel.com \
    --to=aravind.iddamsetty@intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=matthew.auld@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox