On Mon, 11 Nov 2024 13:37:56 +0100
Sebastian Ott wrote:
> PCI hotplug for downstream endpoints on arm fails because Linux'
> PCIe hotplug driver doesn't like the QEMU provided LNKSTA:
>
> pcieport :08:01.0: pciehp: Slot(2): Card present
> pcieport :08:01.0: pciehp: Slot(2): Link Up
>
On Mon, 11 Nov 2024, Sebastian Ott wrote:
PCI hotplug for downstream endpoints on arm fails because Linux'
PCIe hotplug driver doesn't like the QEMU provided LNKSTA:
pcieport :08:01.0: pciehp: Slot(2): Card present
pcieport :08:01.0: pciehp: Slot(2): Link Up
pcieport :08:01.0: pci
}
+if ((lnksta & PCI_EXP_LNKSTA_CLS) > (lnkcap & PCI_EXP_LNKCAP_SLS)) {
+lnksta &= ~PCI_EXP_LNKSTA_CLS;
+lnksta |= lnkcap & PCI_EXP_LNKCAP_SLS;
+}
+if (!(lnksta & PCI_EXP_LNKSTA_CLS)) {
+lnksta |= QEMU_PCI_EXP_LNKSTA_CLS(QEMU_PCI_EXP_LNK_2_5GT);
On Mon, 11 Nov 2024, Sebastian Ott wrote:
PCI hotplug for downstream endpoints on arm fails because Linux'
PCIe hotplug driver doesn't like the QEMU provided LNKSTA:
pcieport :08:01.0: pciehp: Slot(2): Card present
pcieport :08:01.0: pciehp: Slot(2): Link Up
pcieport :08:01.0: pci
PCI hotplug for downstream endpoints on arm fails because Linux'
PCIe hotplug driver doesn't like the QEMU provided LNKSTA:
pcieport :08:01.0: pciehp: Slot(2): Card present
pcieport :08:01.0: pciehp: Slot(2): Link Up
pcieport :08:01.0: pciehp: Slot(2): Cannot train link: status 0