Skip to content

Commit 60b78ed

Browse files
Evan Quanbjorn-helgaas
authored andcommitted
PCI: Add AMD GPU multi-function power dependencies
Some AMD GPUs have built-in USB xHCI and USB Type-C UCSI controllers with power dependencies between the GPU and the other functions as in 6d2e369 ("PCI: Add NVIDIA GPU multi-function power dependencies"). Add device link support for the AMD integrated USB xHCI and USB Type-C UCSI controllers. Without this, runtime power management, including GPU resume and temp and fan sensors don't work correctly. Reported-at: https://gitlab.freedesktop.org/drm/amd/-/issues/1704 Link: https://lore.kernel.org/r/20210903063311.3606226-1-evan.quan@amd.com Signed-off-by: Evan Quan <evan.quan@amd.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Cc: stable@vger.kernel.org
1 parent 6bd6597 commit 60b78ed

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

drivers/pci/quirks.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5435,7 +5435,7 @@ DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_VENDOR_ID_NVIDIA, PCI_ANY_ID,
54355435
PCI_CLASS_MULTIMEDIA_HD_AUDIO, 8, quirk_gpu_hda);
54365436

54375437
/*
5438-
* Create device link for NVIDIA GPU with integrated USB xHCI Host
5438+
* Create device link for GPUs with integrated USB xHCI Host
54395439
* controller to VGA.
54405440
*/
54415441
static void quirk_gpu_usb(struct pci_dev *usb)
@@ -5444,9 +5444,11 @@ static void quirk_gpu_usb(struct pci_dev *usb)
54445444
}
54455445
DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_VENDOR_ID_NVIDIA, PCI_ANY_ID,
54465446
PCI_CLASS_SERIAL_USB, 8, quirk_gpu_usb);
5447+
DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_VENDOR_ID_ATI, PCI_ANY_ID,
5448+
PCI_CLASS_SERIAL_USB, 8, quirk_gpu_usb);
54475449

54485450
/*
5449-
* Create device link for NVIDIA GPU with integrated Type-C UCSI controller
5451+
* Create device link for GPUs with integrated Type-C UCSI controller
54505452
* to VGA. Currently there is no class code defined for UCSI device over PCI
54515453
* so using UNKNOWN class for now and it will be updated when UCSI
54525454
* over PCI gets a class code.
@@ -5459,6 +5461,9 @@ static void quirk_gpu_usb_typec_ucsi(struct pci_dev *ucsi)
54595461
DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_VENDOR_ID_NVIDIA, PCI_ANY_ID,
54605462
PCI_CLASS_SERIAL_UNKNOWN, 8,
54615463
quirk_gpu_usb_typec_ucsi);
5464+
DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_VENDOR_ID_ATI, PCI_ANY_ID,
5465+
PCI_CLASS_SERIAL_UNKNOWN, 8,
5466+
quirk_gpu_usb_typec_ucsi);
54625467

54635468
/*
54645469
* Enable the NVIDIA GPU integrated HDA controller if the BIOS left it

0 commit comments

Comments
 (0)