linux_dsm_epyc7002/drivers/net/ethernet
Bjorn Helgaas 4695ca9d17 ixgbe: 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.

The dmesg change is:

  - PCI Express bandwidth of %dGT/s available
  - (Speed:%s, Width: x%d, Encoding Loss:%s)
  + %u.%03u Gb/s available PCIe bandwidth (%s x%d link)

or, if the device is capable of better performance than is available in the
current slot:

  - This is not sufficient for optimal performance of this card.
  - For optimal performance, at least %dGT/s of bandwidth is required.
  - A slot with more lanes and/or higher speed is suggested.
  + %u.%03u Gb/s available PCIe bandwidth, limited by %s x%d link at %s (capable of %u.%03u Gb/s with %s x%d link)

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: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2018-05-25 17:29:49 -05:00
..
3com 3c59x: fix missing dma_mapping_error check and bad ring refill logic 2018-01-03 13:44:14 -05:00
8390 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2018-04-03 14:04:18 -07:00
adaptec
aeroflex
agere
alacritech
allwinner
alteon
altera ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
amazon net: ena: Eliminate duplicate barriers on weakly-ordered archs 2018-03-26 12:47:56 -04:00
amd ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
apm
apple net/macmace: Drop redundant MACH_IS_MAC test 2018-02-28 12:00:27 -05:00
aquantia net: aquantia: oops when shutdown on already stopped device 2018-04-11 10:41:36 -04:00
arc net: ethernet: arc: Fix a potential memory leak if an optional regulator is deferred 2018-03-20 12:06:23 -04:00
atheros
aurora
broadcom bnxt_en: Report PCIe link properties with pcie_print_link_status() 2018-05-25 17:29:49 -05:00
brocade ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
cadence treewide: fix up files incorrectly marked executable 2018-04-07 13:31:23 -07:00
calxeda
cavium net: thunderx: rework mac addresses list to u64 array 2018-04-09 10:59:38 -04:00
chelsio cxgb4: Report PCIe link properties with pcie_print_link_status() 2018-05-25 17:29:49 -05:00
cirrus net/mac89x0: Replace custom debug logging with netif_* calls 2018-03-01 21:21:36 -05:00
cisco enic: drop IP proto check for vxlan tunnel delete 2018-03-16 09:50:40 -04:00
cortina net: gemini: fix memory leak 2018-03-20 12:08:45 -04:00
davicom treewide: simplify Kconfig dependencies for removed archs 2018-03-26 15:55:57 +02:00
dec
dlink
emulex ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
ezchip
faraday net: faraday add nds32 support. 2018-02-22 10:44:36 +08:00
freescale net/fsl_pq_mdio: Allow explicit speficition of TBIPA address 2018-04-08 12:44:49 -04:00
fujitsu
hisilicon net: hns3: fix length overflow when CONFIG_ARM64_64K_PAGES 2018-04-04 11:46:14 -04:00
hp
huawei hinic: Replace PCI pool old API 2018-01-02 16:14:49 -06:00
i825xx
ibm ibmvnic: Do not reset CRQ for Mobility driver resets 2018-04-08 12:39:47 -04:00
intel ixgbe: Report PCIe link properties with pcie_print_link_status() 2018-05-25 17:29:49 -05:00
marvell net: mvpp2: Fix parser entry init boundary check 2018-04-05 22:13:16 -04:00
mediatek net: mediatek: Explicitly include pinctrl headers 2018-02-05 09:41:54 -08:00
mellanox Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2018-04-09 17:04:10 -07:00
micrel
microchip lan743x: make functions lan743x_csr_read and lan743x_csr_read static 2018-03-12 11:12:38 -04:00
moxa
myricom ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
natsemi Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2018-03-23 11:31:58 -04:00
neterion
netronome nfp: use full 40 bits of the NSP buffer address 2018-04-04 11:45:24 -04:00
ni net: ethernet: nixge: Add support for National Instruments XGE netdev 2018-03-29 11:51:00 -04:00
nuvoton
nvidia forcedeth: remove duplicate structure member in rx 2018-01-23 11:11:41 -05:00
nxp
oki-semi pch_gbe: Deprecate pci_get_bus_and_slot() 2018-01-17 08:16:46 -06:00
packetengines
pasemi net: pasemi: Replace mac address parsing 2017-12-20 12:47:46 -05:00
qlogic Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2018-04-05 11:56:35 -07:00
qualcomm net: qualcomm: rmnet: check for null ep to avoid null pointer dereference 2018-03-26 12:11:24 -04:00
rdc
realtek Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2018-04-01 19:49:34 -04:00
renesas sh_eth: kill useless check in __sh_eth_get_regs() 2018-04-01 14:09:53 -04:00
rocker rocker: fix possible null pointer dereference in rocker_router_fib_event_work 2018-02-01 09:50:52 -05:00
samsung ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
seeq
sfc More power management updates for 4.17-rc1 2018-04-11 17:03:20 -07:00
sgi
silan
sis
smsc arch: remove obsolete architecture ports 2018-04-02 20:20:12 -07:00
socionext net: ethernet: ave: add UniPhier PXs3 support 2018-03-26 11:29:10 -04:00
stmicro net: stmmac: dwmac-meson8b: Add support for the Meson8m2 SoC 2018-03-31 22:17:24 -04:00
sun ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
synopsys net: dwc-xlgmac: Get rid of custom hex_dump_to_buffer() 2017-12-21 15:05:33 -05:00
tehuti
ti Merge branch 'akpm' (patches from Andrew) 2018-04-06 14:19:26 -07:00
toshiba
tundra net: tsi108: Use DMA API properly 2018-01-17 18:04:43 -06:00
via
wiznet
xilinx
xircom
xscale
dnet.c
dnet.h
ec_bhf.c ethernet: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
ethoc.c
fealnx.c
jme.c net: jme: remove unused initialization of 'rxdesc' 2018-02-01 14:54:28 -05:00
jme.h
Kconfig Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2018-04-03 14:04:18 -07:00
korina.c
lantiq_etop.c
Makefile Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2018-04-03 14:04:18 -07:00
netx-eth.c