diff options
author | Jiri Pirko <jiri@nvidia.com> | 2023-05-26 13:28:33 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2023-05-30 20:32:20 +0300 |
commit | 65a4c44bf9375a5d13287ee1e389b512e83f37eb (patch) | |
tree | d78f3e57b0d34c4062d08445d0909a2f9b898ecb /net/devlink | |
parent | 8a756d91d26c1fe941d6839b41d385a4f84ac453 (diff) | |
download | linux-65a4c44bf9375a5d13287ee1e389b512e83f37eb.tar.xz |
devlink: move port_type_set() op into devlink_port_ops
Move port_type_set() from devlink_ops into newly introduced
devlink_port_ops.
Signed-off-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/devlink')
-rw-r--r-- | net/devlink/leftover.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/devlink/leftover.c b/net/devlink/leftover.c index 1ed95c76cf67..d69e278ae15a 100644 --- a/net/devlink/leftover.c +++ b/net/devlink/leftover.c @@ -1137,14 +1137,13 @@ static int devlink_port_type_set(struct devlink_port *devlink_port, { int err; - if (!devlink_port->devlink->ops->port_type_set) + if (!devlink_port->ops->port_type_set) return -EOPNOTSUPP; if (port_type == devlink_port->type) return 0; - err = devlink_port->devlink->ops->port_type_set(devlink_port, - port_type); + err = devlink_port->ops->port_type_set(devlink_port, port_type); if (err) return err; |