Commit d2d937b7 authored by Myron Stowe's avatar Myron Stowe Committed by Greg Kroah-Hartman
Browse files

PCI: Skip MPS logic for Virtual Functions (VFs)

commit 3dbe97ef upstream.

PCIe r4.0, sec, "Device Control Register", shows both
Max_Payload_Size (MPS) and Max_Read_request_Size (MRRS) to be 'RsvdP' for
VFs.  Just prior to the table it states:

  "PF and VF functionality is defined in Section except where
   noted in Table 9-16.  For VF fields marked 'RsvdP', the PF setting
   applies to the VF."

All of which implies that with respect to Max_Payload_Size Supported
(MPSS), MPS, and MRRS values, we should not be paying any attention to the
VF's fields, but rather only to the PF's.  Only looking at the PF's fields
also logically makes sense as it's the sole physical interface to the PCIe

Fixes: 27d868b5

 ("PCI: Set MPS to match upstream bridge")
Signed-off-by: default avatarMyron Stowe <>
Signed-off-by: default avatarBjorn Helgaas <>
Cc: # 4.3+
Cc: Keith Busch <>
Cc: Sinan Kaya <>
Cc: Dongdong Liu <>
Cc: Jon Mason <>
Signed-off-by: default avatarGreg Kroah-Hartman <>
parent 16558e4d
......@@ -1730,6 +1730,10 @@ static void pci_configure_mps(struct pci_dev *dev)
if (!pci_is_pcie(dev) || !bridge || !pci_is_pcie(bridge))
/* MPS and MRRS fields are of type 'RsvdP' for VFs, short-circuit out */
if (dev->is_virtfn)
mps = pcie_get_mps(dev);
p_mps = pcie_get_mps(bridge);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment