diff options
author | Danielle Ratson <danieller@mellanox.com> | 2020-07-09 15:18:20 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-09 22:15:30 +0200 |
commit | a0f49b54865273c895be3826d6d59cbc5ad725c2 (patch) | |
tree | f31fa3811a4ab42a1d6f45035e7d78473bf2b86a /drivers/net/ethernet/netronome | |
parent | mlxsw: Set port split ability attribute in driver (diff) | |
download | linux-a0f49b54865273c895be3826d6d59cbc5ad725c2.tar.xz linux-a0f49b54865273c895be3826d6d59cbc5ad725c2.zip |
devlink: Add a new devlink port split ability attribute and pass to netlink
Add a new attribute that indicates the split ability of devlink port.
Drivers are expected to set it via devlink_port_attrs_set(), before
registering the port.
Signed-off-by: Danielle Ratson <danieller@mellanox.com>
Reviewed-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/netronome')
-rw-r--r-- | drivers/net/ethernet/netronome/nfp/nfp_devlink.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/netronome/nfp/nfp_devlink.c b/drivers/net/ethernet/netronome/nfp/nfp_devlink.c index 71f4e624b3db..b6a10565309a 100644 --- a/drivers/net/ethernet/netronome/nfp/nfp_devlink.c +++ b/drivers/net/ethernet/netronome/nfp/nfp_devlink.c @@ -367,6 +367,7 @@ int nfp_devlink_port_register(struct nfp_app *app, struct nfp_port *port) return ret; attrs.split = eth_port.is_split; + attrs.splittable = !attrs.split; attrs.flavour = DEVLINK_PORT_FLAVOUR_PHYSICAL; attrs.phys.port_number = eth_port.label_port; attrs.phys.split_subport_number = eth_port.label_subport; |