Re: [PATCH] [HACK] drop zen5_init checks due to segfault

Joshua Hahn
2025-06-17T20:33:22Z

On Tue, 13 May 2025 23:10:36 +0200 Robert Richter <rrichter@amd.com> wrote:

> On 04.04.25 22:38:58, Gregory Price wrote:
> > Unclear why this is occuring, but a raw call to the PRM at this point
> > causes segfaults on my Zen5 system. Later calls to the prm work just
> > fine, and modifying the structure to include pci_dev info still results
> > in a segfault.
> >
> > Debugging this is not possible on my end since the crash happens deep in
> > the ACPI prm code. Seems maybe the PRM interface isn't ready or something?
>
> There is a subsys_initcall order dependency if driver is builtin:
>
> subsys_initcall(cxl_acpi_init);
> subsys_initcall(efisubsys_init);
>
> A fix using subsys_initcall_sync(cxl_acpi_init) solves the issue.
>
> efi_rts_wq workqueue is used by cxl_acpi_init() before its allocation
> in efisubsys_init(). I will address that in the next submission.
>
> Thanks for looking into this.
>
> -Robert
>

Hello Robert,

I hope you are doing well! Sorry for reviving an old thread. I'm currently
trying to apply this patchset, and saw the same issue that Gregory was having.
Keeping the PRM checks would be helpful for debugging when things go wrong, so
I wanted to try and apply your suggestion, but had a bit of trouble
understanding what the core of the problem was.

I was hoping for some help in understanding your explanation here -- I don't
think I can see where the dependency appears. (In particular, I'm having
trouble understanding where the efi_rts_wq dependnecy matters during the
cxl_zen5_init function).

Thank you for this patchset, and for your help!
Joshua

Sent using hkml (https://github.com/sjp38/hackermail)