Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Nirmoy Das <nirmoy.das@intel.com>
To: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	<intel-xe@lists.freedesktop.org>
Cc: Matthew Brost <matthew.brost@intel.com>,
	Francois Dugast <francois.dugast@intel.com>
Subject: Re: [PATCH 2/2] drm/xe/ufence: Warn if mmget_not_zero() fails
Date: Tue, 15 Oct 2024 14:59:49 +0200	[thread overview]
Message-ID: <916aeed1-e9ae-49ba-aa43-2b38e431e9d7@intel.com> (raw)
In-Reply-To: <2c1943fd-3a21-44da-a771-162f3ff160f2@linux.intel.com>


On 10/15/2024 2:48 PM, Maarten Lankhorst wrote:
> Please change this to a XE_IOCTL_DBG, don't use XE_WARN_ON as it can potentially be triggered on process exit.

I missed this point last time. Agree, this can be triggered on process exist, I will make it drm_dbg which is same as XE_IOCTL_DBG. 

XE_IOCTL_DBG would look odd here.


Regards,

Nirmoy

>
> Den 2024-10-15 kl. 11:05, skrev Nirmoy Das:
>> This shouldn't happen but seen this while debugging ufence timeout
>> issue time to time so log it to isolate this particular case.
>>
>> Link: https://gitlab.freedesktop.org/drm/xe/kernel/-/issues/1630
>> Cc: Matthew Brost <matthew.brost@intel.com>
>> Signed-off-by: Nirmoy Das <nirmoy.das@intel.com>
>> Reviewed-by: Francois Dugast <francois.dugast@intel.com>
>> ---
>>  drivers/gpu/drm/xe/xe_sync.c | 2 ++
>>  1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/gpu/drm/xe/xe_sync.c b/drivers/gpu/drm/xe/xe_sync.c
>> index 2e72c06fd40d..22f72df36ab2 100644
>> --- a/drivers/gpu/drm/xe/xe_sync.c
>> +++ b/drivers/gpu/drm/xe/xe_sync.c
>> @@ -83,6 +83,8 @@ static void user_fence_worker(struct work_struct *w)
>>  			XE_WARN_ON("Copy to user failed");
>>  		kthread_unuse_mm(ufence->mm);
>>  		mmput(ufence->mm);
>> +	} else {
>> +		XE_WARN_ON("mmget_not_zero() failed");
>>  	}
>>  
>>  	wake_up_all(&ufence->xe->ufence_wq);

  reply	other threads:[~2024-10-15 13:00 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-15  9:05 [PATCH 0/2] Improve ufence addr validation and error handling Nirmoy Das
2024-10-15  9:05 ` [PATCH 1/2] drm/xe/ufence: Prefetch ufence addr to catch bogus address Nirmoy Das
2024-10-15  9:05 ` [PATCH 2/2] drm/xe/ufence: Warn if mmget_not_zero() fails Nirmoy Das
2024-10-15 12:48   ` Maarten Lankhorst
2024-10-15 12:59     ` Nirmoy Das [this message]
2024-10-15 12:46 ` ✓ CI.Patch_applied: success for Improve ufence addr validation and error handling Patchwork
2024-10-15 12:46 ` ✓ CI.checkpatch: " Patchwork
2024-10-15 12:48 ` ✓ CI.KUnit: " Patchwork
2024-10-15 12:59 ` ✓ CI.Build: " Patchwork
2024-10-15 13:01 ` ✓ CI.Hooks: " Patchwork
2024-10-15 13:03 ` ✓ CI.checksparse: " Patchwork
2024-10-15 21:14 ` ✗ CI.FULL: failure " Patchwork
2024-10-16  5:34 ` ✓ CI.Patch_applied: success for Improve ufence addr validation and error handling (rev2) Patchwork
2024-10-16  5:34 ` ✓ CI.checkpatch: " Patchwork
2024-10-16  5:35 ` ✓ CI.KUnit: " Patchwork
2024-10-16  5:47 ` ✓ CI.Build: " Patchwork
2024-10-16  5:49 ` ✓ CI.Hooks: " Patchwork
2024-10-16  5:51 ` ✓ CI.checksparse: " Patchwork
2024-10-16  6:15 ` ✓ CI.BAT: " Patchwork
2024-10-16 13:56 ` ✗ CI.FULL: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2024-10-11 11:57 [PATCH 1/2] drm/xe/ufence: Prefetch ufence addr to catch bogus address Nirmoy Das
2024-10-11 11:57 ` [PATCH 2/2] drm/xe/ufence: Warn if mmget_not_zero() fails Nirmoy Das
2024-10-14  9:27   ` Francois Dugast
2024-10-14 10:58     ` Maarten Lankhorst
2024-10-14 11:37       ` Francois Dugast

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=916aeed1-e9ae-49ba-aa43-2b38e431e9d7@intel.com \
    --to=nirmoy.das@intel.com \
    --cc=francois.dugast@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --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