[PATCH 4/5] drm/radeon: Don't register Thunderbolt eGPU with vga_switcheroo

Peter Wu peter at lekensteyn.nl
Wed Mar 8 10:46:33 UTC 2017


On Wed, Mar 08, 2017 at 06:01:54AM +0100, Lukas Wunner wrote:
> On Tue, Mar 07, 2017 at 03:30:30PM -0500, Alex Deucher wrote:
> > On Fri, Feb 24, 2017 at 2:19 PM, Lukas Wunner <lukas at wunner.de> wrote:
> > > An external Thunderbolt GPU can neither drive the laptop's panel nor be
> > > powered off by the platform, so there's no point in registering it with
> > > vga_switcheroo.  In fact, when the external GPU is runtime suspended,
> > > vga_switcheroo will cut power to the internal discrete GPU, resulting in
> > > a lockup.
> > 
> > I'm not necessarily opposed to this, but I'd prefer something more
> > generic.  E.g., what happens if someone uses another dGPU in a docking
> > station or some other sort of PCIe bridge?
> 
> Such a dGPU is only relevant to vga_switcheroo if it can either drive
> the panel or be powered off by the platform.  Does such a product exist?
> 
> I've never heard of one, and think that's because such a product doesn't
> make sense:  A docking staton is not power-constrained, it's stationary
> and connected to a wall outlet, so there's no need to power the dGPU off
> when it's not in use.
> 
> And at a docking station you're usually connected to a larger monitor,
> so having the dGPU drive the laptop's smaller panel isn't necessary either.
> In the rare cases where there's no larger monitor, you just use the dGPU
> for render offloading, just as you would for contemporary ATPX laptops.
> 
> OTOH, dGPUs in Thunderbolt enclosures *do* exist and connecting them
> to an ATPX machine causes failure, as explained in the commit message.
> 
> 
> > I think on AMD platforms
> > at least we should be able to determine what devices are the
> > switcheroo devices based on information in the ATIF and ATPX ACPI
> > methods.  In that case, we can be explicit in which devices we
> > register with vga_switcheroo.
> 
> Is there public documentation on these methods somewhere?

The ACPI interface is documented in
drivers/gpu/drm/amd/include/amd_acpi.h while
drivers/gpu/drm/amd/amdgpu/amdgpu_atpx_handler.c contains some glue for
ACPI and the amdgpu driver (similar code exists for radeon).
-- 
Kind regards,
Peter Wu
https://lekensteyn.nl


More information about the amd-gfx mailing list