nfp: support port splitting via devlink
authorJakub Kicinski <jakub.kicinski@netronome.com>
Fri, 26 May 2017 08:03:36 +0000 (01:03 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 26 May 2017 15:01:49 +0000 (11:01 -0400)
commitec8b1fbe682deb376062c5ed04ef9c78160ffbf0
tree778e83b04aede19923261c5cd4ed443c10498b43
parentf0b81195381f0fd9ec84009a0e5a4bb12ccc9637
nfp: support port splitting via devlink

Add support for configuring port split with devlink.  Add devlink
callbacks to validate requested config and call NSP helpers.
Getting the right nfp_port structure can be done with simple iteration.

Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Simon Horman <simon.horman@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/netronome/nfp/nfp_devlink.c
drivers/net/ethernet/netronome/nfp/nfp_net_main.c
drivers/net/ethernet/netronome/nfp/nfp_port.c
drivers/net/ethernet/netronome/nfp/nfp_port.h