linux/drivers/infiniband/hw
Michael J. Ruhl 4c009af473 IB/hfi: Only read capability registers if the capability exists
During driver init, various registers are saved to allow restoration
after an FLR or gen3 bump.  Some of these registers are not available
in some circumstances (i.e. Virtual machines).

This bug makes the driver unusable when the PCI device is passed into
a VM, it fails during probe.

Delete unnecessary register read/write, and only access register if
the capability exists.

Cc: <stable@vger.kernel.org> # 4.14.x
Fixes: a618b7e40a ("IB/hfi1: Move saving PCI values to a separate function")
Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Michael J. Ruhl <michael.j.ruhl@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
2017-12-22 10:42:08 -07:00
..
bnxt_re Updates for 4.15 kernel merge window 2017-11-15 14:54:53 -08:00
cxgb3 Updates for 4.15 kernel merge window 2017-11-15 14:54:53 -08:00
cxgb4 iw_cxgb4: when flushing, complete all wrs in a chain 2017-12-21 16:06:06 -07:00
hfi1 IB/hfi: Only read capability registers if the capability exists 2017-12-22 10:42:08 -07:00
hns RDMA/hns: Get rid of page operation after dma_alloc_coherent 2017-12-01 12:21:27 -07:00
i40iw i40iw: Notify user of established connection after QP in RTS 2017-12-01 12:21:26 -07:00
mlx4 IB/mlx4: Fix RSS hash fields restrictions 2017-12-07 15:28:07 -05:00
mlx5 IB/mlx5: Fix congestion counters in LAG mode 2017-12-21 16:06:07 -07:00
mthca treewide: setup_timer() -> timer_setup() (2 field) 2017-11-21 15:57:09 -08:00
nes treewide: Remove TIMER_FUNC_TYPE and TIMER_DATA_TYPE casts 2017-11-21 16:35:54 -08:00
ocrdma IB/ocrdma_hw: remove unnecessary code in ocrdma_mbx_dealloc_lkey 2017-11-13 16:18:33 -05:00
qedr Updates for 4.15 kernel merge window 2017-11-15 14:54:53 -08:00
qib Merge branch 'akpm' (patches from Andrew) 2017-11-15 19:42:40 -08:00
usnic Updates for 4.15 kernel merge window 2017-11-15 14:54:53 -08:00
vmw_pvrdma RDMA/vmw_pvrdma: Avoid use after free due to QP/CQ/SRQ destroy 2017-12-21 16:06:07 -07:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00