[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <CADnq5_NG_dQCYwqHM0umjTMg5Uud6zC4=MiscH91Y9v7mW9bJA@mail.gmail.com>
Date: Wed, 16 Feb 2022 11:37:07 -0500
From: Alex Deucher <alexdeucher@...il.com>
To: "James D. Turner" <linuxkernel.foss@...rc-none.turner.link>
Cc: Thorsten Leemhuis <regressions@...mhuis.info>,
"Lazar, Lijo" <lijo.lazar@....com>,
"Deucher, Alexander" <Alexander.Deucher@....com>,
"regressions@...ts.linux.dev" <regressions@...ts.linux.dev>,
"kvm@...r.kernel.org" <kvm@...r.kernel.org>,
Greg KH <gregkh@...uxfoundation.org>,
"Pan, Xinhui" <Xinhui.Pan@....com>,
LKML <linux-kernel@...r.kernel.org>,
"amd-gfx@...ts.freedesktop.org" <amd-gfx@...ts.freedesktop.org>,
Alex Williamson <alex.williamson@...hat.com>,
"Koenig, Christian" <Christian.Koenig@....com>
Subject: Re: [REGRESSION] Too-low frequency limit for AMD GPU
PCI-passed-through to Windows VM
On Tue, Feb 15, 2022 at 9:35 PM James D. Turner
<linuxkernel.foss@...rc-none.turner.link> wrote:
>
> Hi Alex,
>
> > I guess just querying the ATIF method does something that negatively
> > influences the windows driver in the guest. Perhaps the platform
> > thinks the driver has been loaded since the method has been called so
> > it enables certain behaviors that require ATIF interaction that never
> > happen because the ACPI methods are not available in the guest.
>
> Do you mean the `amdgpu_atif_pci_probe_handle` function? If it would be
> helpful, I could try disabling that function and testing again.
Correct.
>
> > I don't really have a good workaround other than blacklisting the
> > driver since on bare metal the driver needs to use this interface for
> > platform interactions.
>
> I'm not familiar with ATIF, but should `amdgpu_atif_pci_probe_handle`
> really be called for PCI devices which are bound to vfio-pci? I'd expect
> amdgpu to ignore such devices.
>
> As I understand it, starting with
> f9b7f3703ff9 ("drm/amdgpu/acpi: make ATPX/ATCS structures global (v2)"),
> the `amdgpu_acpi_detect` function loops over all PCI devices in the
> `PCI_CLASS_DISPLAY_VGA` and `PCI_CLASS_DISPLAY_OTHER` classes to find
> the ATIF and ATCS handles. Maybe skipping over any PCI devices bound to
> vfio-pci would fix the issue? On a related note, shouldn't it also skip
> over any PCI devices with non-AMD vendor IDs?
The ACPI methods are global. There's only one instance of each per
system and they are relevant to add GPUs on the platform. That's why
they are a global resource in the driver. They can be hung off of the
dGPU or APU ACPI namespace, depending on the platform which is why we
check all of the display devices. Skipping them would prevent them
from being available if you later bound the amdgpu driver to the GPU
device(s) I think.
Alex
>
> Regards,
> James
Powered by blists - more mailing lists