]> git.baikalelectronics.ru Git - kernel.git/commit
nfp: only try to get to PCIe ctrl memory if BARs are wide enough
authorJakub Kicinski <jakub.kicinski@netronome.com>
Mon, 29 May 2017 00:52:56 +0000 (17:52 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 30 May 2017 15:27:04 +0000 (11:27 -0400)
commit12f057b9527aada044625bb21987f34bf6141da1
treee64a8286047d40facbba50627233ca9b7f94672a
parent04bf24e04fb2494ccea22164d2079eee9fb9089f
nfp: only try to get to PCIe ctrl memory if BARs are wide enough

For accessing PCIe ctrl memory we depend on the BAR aperture being
large enough to reach all registers.  Since the BAR aperture can
be set in the flash make sure the driver won't oops the kernel
when the PCIe configuration is unusual.

Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c