From: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
To: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
Cc: Matthew Brost <matthew.brost@intel.com>,
<intel-xe@lists.freedesktop.org>,
Jonathan Cavitt <jonathan.cavitt@intel.com>
Subject: Re: [PATCH] drm/xe/oa: Disallow OA from being enabled on active exec_queue's
Date: Thu, 21 Nov 2024 14:06:56 -0800 [thread overview]
Message-ID: <Zz+vAIHQaXztwn0Y@orsosgc001> (raw)
In-Reply-To: <851pz76ie6.wl-ashutosh.dixit@intel.com>
On Tue, Nov 19, 2024 at 01:08:49PM -0800, Dixit, Ashutosh wrote:
>On Tue, 19 Nov 2024 06:44:51 -0800, Matthew Brost wrote:
>>
>> On Mon, Nov 18, 2024 at 05:32:56PM -0800, Ashutosh Dixit wrote:
>> > Enabling OA on an exec_queue toggles the OAC_CONTEXT_ENABLE bit in
>> > CTXT_SR_CTL register. Toggling this bit changes the size and layout of the
>> > underlying HW context image. Therefore, enabling OA on an already active
>> > exec_queue (as currently implemented in xe) is an invalid operation and can
>> > cause hangs. Therefore, disallow OA from being enabled on active
>> > exec_queue's (here, by active we mean a context on which submissions have
>> > previously happened).
>> >
>>
>> This is something we will need to keep on eye on then because in various
>> experimental code I've played around enabling exec queues upon creation.
>> e.g., If we want to allocate a doorbell. I seem to recall Habana wanting
>> to enable exec queues upon creation too.
>
>The real requirement here is that HW context image should not have been
>loaded before OA is enabled on the exec queue. That is what happens today
>in the ENABLED state, correct, when user space submissions start?
>
>If operations such as doorbell are only management requests to GuC (which
>don't cause HW context image to be loaded) and if we can name a new state
>when the exec queue is handed off to userspace for starting submissions, we
>should be able to stay with this approach.
>
>> Just curious if it was ever explored having exec queue creation
>> extension which enables OA? It seems like this is something we may need
>> at some point if our exec queue creation semantics change of course
>> being careful to not break existing flows.
>
>Yeah I did think of it but didn't want to change the uapi.
>
>Also, a different implementation is possible which avoids this resizing of
>the context image altogether. It requires the kernel OA code submit its
>submissions on the user exec queue (and use that exec queue's VM, currently
>OA code uses a kernel exec queue). There are some reasons I don't want to
>implement that just yet, but worst case, we can do that if absolutely
>needed.
Just curious about why we are not going with the LRI command to set this
bit in the context control. I think it should just be an MI_LRI
submitted to the ring directly. More in the lines of
xe_lrc_write_ring(). If that works, then we can avoid this patch and
also revert the one that Jose had added as a work around.
Regards,
Umesh
>
>Thanks.
>--
>Ashutosh
next prev parent reply other threads:[~2024-11-21 22:07 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-19 1:32 [PATCH] drm/xe/oa: Disallow OA from being enabled on active exec_queue's Ashutosh Dixit
2024-11-19 2:10 ` ✓ CI.Patch_applied: success for " Patchwork
2024-11-19 2:10 ` ✓ CI.checkpatch: " Patchwork
2024-11-19 2:11 ` ✓ CI.KUnit: " Patchwork
2024-11-19 2:29 ` ✓ CI.Build: " Patchwork
2024-11-19 2:32 ` ✓ CI.Hooks: " Patchwork
2024-11-19 2:33 ` ✓ CI.checksparse: " Patchwork
2024-11-19 3:00 ` ✓ CI.BAT: " Patchwork
2024-11-19 14:44 ` [PATCH] " Matthew Brost
2024-11-19 21:08 ` Dixit, Ashutosh
2024-11-19 22:09 ` Matthew Brost
2024-11-21 4:22 ` Dixit, Ashutosh
2024-11-21 5:16 ` Matthew Brost
2024-11-21 21:04 ` Dixit, Ashutosh
2024-11-21 22:06 ` Umesh Nerlige Ramappa [this message]
2024-11-22 2:38 ` Dixit, Ashutosh
2024-11-22 17:49 ` Dixit, Ashutosh
2024-11-19 15:19 ` Cavitt, Jonathan
2024-11-19 15:46 ` ✗ CI.FULL: 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=Zz+vAIHQaXztwn0Y@orsosgc001 \
--to=umesh.nerlige.ramappa@intel.com \
--cc=ashutosh.dixit@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=jonathan.cavitt@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