From: fei.yang@intel.com
To: intel-xe@lists.freedesktop.org
Cc: matthew.brost@intel.com, Fei Yang <fei.yang@intel.com>
Subject: [PATCH 1/1] drm/xe: fixing endless PF range response
Date: Tue, 6 Oct 2026 14:34:48 -0700 [thread overview]
Message-ID: <20261006213449.4027749-2-fei.yang@intel.com> (raw)
In-Reply-To: <20261006213449.4027749-1-fei.yang@intel.com>
From: Fei Yang <fei.yang@intel.com>
[334.635636] PF range response: start=0x80200000 end=0xc0200000 pages=262144 (more ranges pending)
...
[519.065737] PF range response: start=0x5ca140200000 ... (still going, 94888 messages logged)
SVM handler narrows the serviced range through functions
xe_pagefault_set_[start|end]_addr, which updates only the
consumer.[page|end]_addr. However a different field is used
for "immediate ack" cache, xe4_guc_ack_fault_range() reads
vma_info. This causes the ack fault to loop through the
whole address space with 1G pages, and that is wrong and
the loop takes a long while to complete.
VLK-99796
Assisted-by: GitHub_Copilot:claude-opus-5
Signed-off-by: Fei Yang <fei.yang@intel.com>
---
drivers/gpu/drm/xe/xe_pagefault.c | 7 ++++++-
drivers/gpu/drm/xe/xe_pagefault.h | 2 ++
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/xe/xe_pagefault.c b/drivers/gpu/drm/xe/xe_pagefault.c
index 5247321c805ec..72dfe27025736 100644
--- a/drivers/gpu/drm/xe/xe_pagefault.c
+++ b/drivers/gpu/drm/xe/xe_pagefault.c
@@ -694,6 +694,8 @@ static void xe_pagefault_queue_work(struct work_struct *w)
/* Last fault same address, ack immediately */
if (xe_pagefault_match(pf, cache_start, cache_end, cache_asid)) {
xe_gt_stats_incr(gt, XE_GT_STATS_ID_LAST_PAGEFAULT_COUNT, 1);
+ xe_pagefault_set_start_addr(pf, cache_start);
+ xe_pagefault_set_end_addr(pf, cache_end);
goto ack_fault;
}
@@ -751,9 +753,12 @@ static void xe_pagefault_queue_work(struct work_struct *w)
pf = xe_pagefault_queue_unchain_requeue(pf_queue, pf, gt);
/* Ensure resets are safe */
- if (pf)
+ if (pf) {
pf->consumer.alloc_state =
XE_PAGEFAULT_ALLOC_STATE_ACTIVE;
+ xe_pagefault_set_start_addr(pf, cache_start);
+ xe_pagefault_set_end_addr(pf, cache_end);
+ }
spin_unlock_irq(&pf_queue->lock);
}
diff --git a/drivers/gpu/drm/xe/xe_pagefault.h b/drivers/gpu/drm/xe/xe_pagefault.h
index 799c984dee84f..5ce2f6ed10c56 100644
--- a/drivers/gpu/drm/xe/xe_pagefault.h
+++ b/drivers/gpu/drm/xe/xe_pagefault.h
@@ -98,6 +98,7 @@ xe_pagefault_set_end_addr(struct xe_pagefault *pf, u64 end_addr)
{
pf->consumer.end_addr &= ~XE_PAGEFAULT_END_ADDR_MASK;
pf->consumer.end_addr |= end_addr;
+ pf->consumer.vma_info.end_addr = end_addr;
}
/**
@@ -137,6 +138,7 @@ xe_pagefault_set_start_addr(struct xe_pagefault *pf, u64 start_addr)
{
pf->consumer.page_addr &= XE_PAGEFAULT_ERROR_MASK;
pf->consumer.page_addr |= (start_addr & ~XE_PAGEFAULT_ERROR_MASK);
+ pf->consumer.vma_info.start_addr = start_addr;
}
/**
--
2.43.0
next prev parent reply other threads:[~2026-10-06 21:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-06 21:34 [PATCH 0/1] drm/xe: fixing endless PF range response fei.yang
2026-10-06 21:34 ` fei.yang [this message]
2026-10-06 21:36 ` [PATCH 1/1] " sashiko-bot
2026-10-06 21:36 ` ✗ CI.KUnit: failure for " 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=20261006213449.4027749-2-fei.yang@intel.com \
--to=fei.yang@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