From: "Teres Alexis, Alan Previn" <alan.previn.teres.alexis@intel.com>
To: "tvrtko.ursulin@linux.intel.com" <tvrtko.ursulin@linux.intel.com>,
"intel-gfx@lists.freedesktop.org"
<intel-gfx@lists.freedesktop.org>
Cc: "dri-devel@lists.freedesktop.org" <dri-devel@lists.freedesktop.org>
Subject: Re: [Intel-gfx] [PATCH v5] drm/i915/pxp: Add drm_dbgs for critical PXP events.
Date: Wed, 29 Nov 2023 19:22:00 +0000 [thread overview]
Message-ID: <32a56d7b35070c583c51697bfa3c962d00dbe85c.camel@intel.com> (raw)
In-Reply-To: <1f275bf3-079c-44c1-80d9-3fff76274ae6@linux.intel.com>
On Fri, 2023-11-24 at 08:30 +0000, Tvrtko Ursulin wrote:
> On 22/11/2023 19:15, Alan Previn wrote:
alan:snip
alan: thanks for reviewing.
> > if (iir & GEN12_DISPLAY_STATE_RESET_COMPLETE_INTERRUPT)
> > - pxp->session_events |= PXP_TERMINATION_COMPLETE;
> > + pxp->session_events |= PXP_TERMINATION_COMPLETE | PXP_EVENT_TYPE_IRQ;
>
> This looked to be doing more than adding debug logs, but then no one is
> actually consuming this new flag?!
alan: see below hunk, inside pxp_session_work the drm_dbg that was prints
the "events" that came from above. we need this debug message to uniquely
recognize that contexts pxp keys would get invalidated in response to
a KCR IRQ (as opposed to other known flows that are being reported by other
means like banning hanging contexts, or as part of suspend etc).
NOTE: pxp->session_events does get set in at lease one other path
outside the IRQ (which triggers teardown but not coming from KCR-hw)
This flag is solely for the debug message. Hope this works.
>
> Regards,
>
> Tvrtko
>
> >
> > if (pxp->session_events)
> > queue_work(system_unbound_wq, &pxp->session_work);
> > diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> > index 0a3e66b0265e..091c86e03d1a 100644
> > --- a/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> > +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_session.c
> > @@ -137,8 +137,10 @@ void intel_pxp_terminate(struct intel_pxp *pxp, bool post_invalidation_needs_res
> > static void pxp_terminate_complete(struct intel_pxp *pxp)
> > {
> > /* Re-create the arb session after teardown handle complete */
> > - if (fetch_and_zero(&pxp->hw_state_invalidated))
> > + if (fetch_and_zero(&pxp->hw_state_invalidated)) {
> > + drm_dbg(&pxp->ctrl_gt->i915->drm, "PXP: creating arb_session after invalidation");
> > pxp_create_arb_session(pxp);
> > + }
> >
> > complete_all(&pxp->termination);
> > }
> > @@ -157,6 +159,8 @@ static void pxp_session_work(struct work_struct *work)
> > if (!events)
> > return;
> >
> > + drm_dbg(>->i915->drm, "PXP: processing event-flags 0x%08x", events);
> > +
> > if (events & PXP_INVAL_REQUIRED)
> > intel_pxp_invalidate(pxp);
> >
> > diff --git a/drivers/gpu/drm/i915/pxp/intel_pxp_types.h b/drivers/gpu/drm/i915/pxp/intel_pxp_types.h
> > index 7e11fa8034b2..07864b584cf4 100644
> > --- a/drivers/gpu/drm/i915/pxp/intel_pxp_types.h
> > +++ b/drivers/gpu/drm/i915/pxp/intel_pxp_types.h
> > @@ -124,6 +124,7 @@ struct intel_pxp {
> > #define PXP_TERMINATION_REQUEST BIT(0)
> > #define PXP_TERMINATION_COMPLETE BIT(1)
> > #define PXP_INVAL_REQUIRED BIT(2)
> > +#define PXP_EVENT_TYPE_IRQ BIT(3)
> > };
> >
> > #endif /* __INTEL_PXP_TYPES_H__ */
> >
> > base-commit: 5429d55de723544dfc0630cf39d96392052b27a1
prev parent reply other threads:[~2023-11-29 19:22 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-22 19:15 [Intel-gfx] [PATCH v5] drm/i915/pxp: Add drm_dbgs for critical PXP events Alan Previn
2023-11-23 1:52 ` [Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915/pxp: Add drm_dbgs for critical PXP events. (rev6) Patchwork
2023-11-24 0:50 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2023-11-24 8:30 ` [Intel-gfx] [PATCH v5] drm/i915/pxp: Add drm_dbgs for critical PXP events Tvrtko Ursulin
2023-11-29 19:22 ` Teres Alexis, Alan Previn [this message]
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=32a56d7b35070c583c51697bfa3c962d00dbe85c.camel@intel.com \
--to=alan.previn.teres.alexis@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=tvrtko.ursulin@linux.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