-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge tag 'mlx5-updates-2020-02-27' of git://git.kernel.org/pub/scm/l…
…inux/kernel/git/saeed/linux Saeed Mahameed says: ==================== mlx5-updates-2020-02-27 mlx5 misc updates and minor cleanups: 1) Use per vport tables for mirroring 2) Improve log messages for SW steering (DR) 3) Add devlink fdb_large_groups parameter 4) E-Switch, Allow goto earlier chain 5) Don't allow forwarding between uplink representors 6) Add support for devlink-port in non-representors mode 7) Minor misc cleanups ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
- Loading branch information
Showing
30 changed files
with
519 additions
and
129 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
// SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB | ||
/* Copyright (c) 2020, Mellanox Technologies inc. All rights reserved. */ | ||
|
||
#include "en/devlink.h" | ||
|
||
int mlx5e_devlink_phy_port_register(struct net_device *dev) | ||
{ | ||
struct mlx5e_priv *priv; | ||
struct devlink *devlink; | ||
int err; | ||
|
||
priv = netdev_priv(dev); | ||
devlink = priv_to_devlink(priv->mdev); | ||
|
||
devlink_port_attrs_set(&priv->dl_phy_port, | ||
DEVLINK_PORT_FLAVOUR_PHYSICAL, | ||
PCI_FUNC(priv->mdev->pdev->devfn), | ||
false, 0, | ||
NULL, 0); | ||
err = devlink_port_register(devlink, &priv->dl_phy_port, 1); | ||
if (err) | ||
return err; | ||
devlink_port_type_eth_set(&priv->dl_phy_port, dev); | ||
return 0; | ||
} | ||
|
||
void mlx5e_devlink_phy_port_unregister(struct mlx5e_priv *priv) | ||
{ | ||
devlink_port_unregister(&priv->dl_phy_port); | ||
} | ||
|
||
struct devlink_port *mlx5e_get_devlink_phy_port(struct net_device *dev) | ||
{ | ||
struct mlx5e_priv *priv = netdev_priv(dev); | ||
|
||
return &priv->dl_phy_port; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */ | ||
/* Copyright (c) 2020, Mellanox Technologies inc. All rights reserved. */ | ||
|
||
#ifndef __MLX5E_EN_DEVLINK_H | ||
#define __MLX5E_EN_DEVLINK_H | ||
|
||
#include <net/devlink.h> | ||
#include "en.h" | ||
|
||
int mlx5e_devlink_phy_port_register(struct net_device *dev); | ||
void mlx5e_devlink_phy_port_unregister(struct mlx5e_priv *priv); | ||
struct devlink_port *mlx5e_get_devlink_phy_port(struct net_device *dev); | ||
|
||
#endif | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.