Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Ghimiray, Himal Prasad" <himal.prasad.ghimiray@intel.com>
To: Matthew Brost <matthew.brost@intel.com>
Cc: <intel-xe@lists.freedesktop.org>,
	Badal Nilawar <badal.nilawar@intel.com>,
	 Ashutosh Dixit <ashutosh.dixit@intel.com>
Subject: Re: [PATCH 1/2] drm/xe/vm: Use xe_vm_lock()/xe_vm_unlock() helpers
Date: Wed, 24 Apr 2024 09:27:45 +0530	[thread overview]
Message-ID: <19d1ea6e-eea8-4a14-a886-740f1f8a4464@intel.com> (raw)
In-Reply-To: <ZiiCi8RUNDytoZoS@DUT025-TGLU.fm.intel.com>


On 24-04-2024 09:24, Matthew Brost wrote:
> On Wed, Apr 24, 2024 at 09:27:55AM +0530, Himal Prasad Ghimiray wrote:
>> There is no change in functionality. Using the helper function
>> defined within the driver.
>>
>> -v2
>> Use xe_vm_unlock() (Ashutosh/Matt)
>>
>> Reviewed-by: Badal Nilawar <badal.nilawar@intel.com>
>> Cc: Matthew Brost <matthew.brost@intel.com>
>> Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
>> Signed-off-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>
>> ---
>>   drivers/gpu/drm/xe/xe_vm.c | 4 ++--
>>   1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/xe/xe_vm.c b/drivers/gpu/drm/xe/xe_vm.c
>> index 85d6f359142d..c350c561e7d9 100644
>> --- a/drivers/gpu/drm/xe/xe_vm.c
>> +++ b/drivers/gpu/drm/xe/xe_vm.c
>> @@ -1279,7 +1279,7 @@ struct xe_vm *xe_vm_create(struct xe_device *xe, u32 flags)
>>   
>>   	drm_gem_object_put(vm_resv_obj);
>>   
>> -	err = dma_resv_lock_interruptible(xe_vm_resv(vm), NULL);
>> +	err = xe_vm_lock(vm, true);
>>   	if (err)
>>   		goto err_close;
>>   
>> @@ -1323,7 +1323,7 @@ struct xe_vm *xe_vm_create(struct xe_device *xe, u32 flags)
>>   
>>   		xe_pt_populate_empty(tile, vm, vm->pt_root[id]);
>>   	}
>> -	dma_resv_unlock(xe_vm_resv(vm));
>> +	xe_vm_unlock(vm);
> There is another dma_resv_unlock below the label 'err_unlock_close' too.
>
> Matt


Thanks Matt, Addressing it in next version.


>
>>   
>>   	/* Kernel migration VM shouldn't have a circular loop.. */
>>   	if (!(flags & XE_VM_FLAG_MIGRATION)) {
>> -- 
>> 2.25.1
>>

  reply	other threads:[~2024-04-24  3:58 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-24  3:57 [PATCH v2 0/2] Use the helpers for locking/unlocking resv object Himal Prasad Ghimiray
2024-04-24  3:57 ` [PATCH 1/2] drm/xe/vm: Use xe_vm_lock()/xe_vm_unlock() helpers Himal Prasad Ghimiray
2024-04-24  3:54   ` Matthew Brost
2024-04-24  3:57     ` Ghimiray, Himal Prasad [this message]
2024-04-24  4:05       ` Nilawar, Badal
2024-04-24  4:09         ` Nilawar, Badal
2024-04-24  3:57 ` [PATCH 2/2] drm/xe: Use xe_bo_lock()/xe_bo_unlock() helpers Himal Prasad Ghimiray
2024-04-24  3:55   ` Matthew Brost

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=19d1ea6e-eea8-4a14-a886-740f1f8a4464@intel.com \
    --to=himal.prasad.ghimiray@intel.com \
    --cc=ashutosh.dixit@intel.com \
    --cc=badal.nilawar@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=matthew.brost@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