net/nfp: use generic PCI config access functions
authorAlejandro Lucero <alejandro.lucero@netronome.com>
Mon, 18 Jun 2018 20:06:12 +0000 (21:06 +0100)
committerFerruh Yigit <ferruh.yigit@intel.com>
Mon, 2 Jul 2018 23:35:58 +0000 (01:35 +0200)
commitebf2ed7208babc8c4a6b06b336e78e3cc0faae63
tree00efa533cbc022d3d51e212f0e9a25c232a344fb
parent2a4ed72338d7030ce1bbb0cee8aa213cdae6b54c
net/nfp: use generic PCI config access functions

This patch avoids direct access to device config sysfs file using
rte_pci_read_config instead.

Apart from replicating code, it turns out this direct access does
not always work if non-root users execute DPDK apps. In those cases
it is mandatory to go through VFIO specific function for reading pci
config space.

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
drivers/net/nfp/nfp_net.c
drivers/net/nfp/nfpcore/nfp_cpp.h
drivers/net/nfp/nfpcore/nfp_cpp_pcie_ops.c
drivers/net/nfp/nfpcore/nfp_cppcore.c