aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorBjorn Helgaas <bhelgaas@google.com>2018-03-30 14:22:44 -0500
committerBjorn Helgaas <helgaas@kernel.org>2018-04-03 08:58:34 -0500
commit170648fda93729f05d0758c76b8cd9170408471b (patch)
tree5aa2951601ca5aca2730b58897ffa0061b921286 /include
parentnet/mlx5e: Use pcie_bandwidth_available() to compute bandwidth (diff)
downloadlinux-dev-170648fda93729f05d0758c76b8cd9170408471b.tar.xz
linux-dev-170648fda93729f05d0758c76b8cd9170408471b.zip
fm10k: Report PCIe link properties with pcie_print_link_status()
Previously the driver used pcie_get_minimum_link() to warn when the NIC is in a slot that can't supply as much bandwidth as the NIC could use. pcie_get_minimum_link() can be misleading because it finds the slowest link and the narrowest link (which may be different links) without considering the total bandwidth of each link. For a path with a 16 GT/s x1 link and a 2.5 GT/s x16 link, it returns 2.5 GT/s x1, which corresponds to 250 MB/s of bandwidth, not the true available bandwidth of about 1969 MB/s for a 16 GT/s x1 link. Use pcie_print_link_status() to report PCIe link speed and possible limitations instead of implementing this in the driver itself. This finds the slowest link in the path to the device by computing the total bandwidth of each link and compares that with the capabilities of the device. Note that the driver previously used dev_warn() to suggest using a different slot, but pcie_print_link_status() uses dev_info() because if the platform has no faster slot available, the user can't do anything about the warning and may not want to be bothered with it. Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Jacob Keller <jacob.e.keller@intel.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions