From: Matthew Brost <matthew.brost@intel.com>
To: Lucas De Marchi <lucas.demarchi@intel.com>
Cc: <intel-xe@lists.freedesktop.org>
Subject: Re: [PATCH v2 5/6] drm/xe: Move HuC init before GuC init
Date: Tue, 20 Aug 2024 21:02:37 +0000 [thread overview]
Message-ID: <ZsUEbUXXf8STbNK0@DUT025-TGLU.fm.intel.com> (raw)
In-Reply-To: <gbqo3m4judjcvi3zfq263xgwfzcvxvcibaws2b4h4ahxm6pchr@ur6r4uf2ndx6>
On Tue, Aug 20, 2024 at 03:42:35PM -0500, Lucas De Marchi wrote:
> On Tue, Aug 20, 2024 at 10:29:57AM GMT, Matthew Brost wrote:
> > The GuC fini, also fini the HuC so move HuC init first.
>
> AFAIU this is about
>
> guc_fini_hw()
> xe_uc_fini_hw()
> xe_uc_sanitize_reset()
> xe_uc_sanitize()
> xe_huc_sanitize()
> xe_guc_sanitize()
>
>
> but why exactly do we do that layering? Shouldn't xe_uc_init()
> be the one adding an action to xe_uc_fini_hw() or let each of the
> uc to sanitize itself?
>
Yea we probably should just cleanup fini call stack so each of UC
sanitize itself. Was lazy with this fix, will respin with a proper fix.
Matt
> >
> > Signed-off-by: Matthew Brost <matthew.brost@intel.com>
> > ---
> > drivers/gpu/drm/xe/xe_uc.c | 8 ++++----
> > 1 file changed, 4 insertions(+), 4 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/xe/xe_uc.c b/drivers/gpu/drm/xe/xe_uc.c
> > index 0d073a9987c2..5b7d6f44a7de 100644
> > --- a/drivers/gpu/drm/xe/xe_uc.c
> > +++ b/drivers/gpu/drm/xe/xe_uc.c
> > @@ -36,6 +36,10 @@ int xe_uc_init(struct xe_uc *uc)
> > {
> > int ret;
> >
> > + ret = xe_huc_init(&uc->huc);
> > + if (ret)
> > + goto err;
> > +
>
> if we are keeping this patch, then the comment below should be on top,
> or maybe even on top of the function.
>
> Lucas De Marchi
>
> > /*
> > * We call the GuC/HuC/GSC init functions even if GuC submission is off
> > * to correctly move our tracking of the FW state to "disabled".
> > @@ -44,10 +48,6 @@ int xe_uc_init(struct xe_uc *uc)
> > if (ret)
> > goto err;
> >
> > - ret = xe_huc_init(&uc->huc);
> > - if (ret)
> > - goto err;
> > -
> > ret = xe_gsc_init(&uc->gsc);
> > if (ret)
> > goto err;
> > --
> > 2.34.1
> >
next prev parent reply other threads:[~2024-08-20 21:04 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-20 17:29 [PATCH v2 0/6] Driver load failure fixes Matthew Brost
2024-08-20 17:29 ` [PATCH v2 1/6] drm/xe: Move ggtt_fini to devm managed Matthew Brost
2024-08-23 13:43 ` Lucas De Marchi
2024-08-20 17:29 ` [PATCH v2 2/6] drm/xe: Set firmware state to loadable before registering guc_fini_hw Matthew Brost
2024-08-20 21:04 ` Lucas De Marchi
2024-08-20 17:29 ` [PATCH v2 3/6] drm/xe: Drop warn on xe_guc_pc_gucrc_disable in guc pc fini Matthew Brost
2024-08-20 18:02 ` Randhawa, Jagmeet
2024-08-20 17:29 ` [PATCH v2 4/6] drm/xe: Move hw_engine_fini to devm managed Matthew Brost
2024-08-20 20:48 ` Lucas De Marchi
2024-08-20 17:29 ` [PATCH v2 5/6] drm/xe: Move HuC init before GuC init Matthew Brost
2024-08-20 20:42 ` Lucas De Marchi
2024-08-20 21:02 ` Matthew Brost [this message]
2024-08-20 17:29 ` [PATCH v2 6/6] drm/xe: Update xe_sa to use xe_managed_bo_create_pin_map Matthew Brost
2024-08-20 21:07 ` Lucas De Marchi
2024-08-20 19:07 ` ✓ CI.Patch_applied: success for Driver load failure fixes Patchwork
2024-08-20 19:07 ` ✓ CI.checkpatch: " Patchwork
2024-08-20 19:09 ` ✓ CI.KUnit: " Patchwork
2024-08-20 19:20 ` ✓ CI.Build: " Patchwork
2024-08-20 19:23 ` ✓ CI.Hooks: " Patchwork
2024-08-20 19:24 ` ✓ CI.checksparse: " Patchwork
2024-08-20 19:46 ` ✗ CI.BAT: failure " Patchwork
2024-08-21 2:05 ` ✗ CI.FULL: " 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=ZsUEbUXXf8STbNK0@DUT025-TGLU.fm.intel.com \
--to=matthew.brost@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=lucas.demarchi@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