]> 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)
commitbf40bb4b97f20d6d6f4b8c418853870be4669866
treee64a8286047d40facbba50627233ca9b7f94672a
parent271521850516baff68a59d11bb1392d09649b146
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