Commit f1b1f273 authored by Petr Machata's avatar Petr Machata Committed by David S. Miller

mlxsw: spectrum_router: Simplify a piece of code

Signed-off-by: default avatarPetr Machata <petrm@mellanox.com>
Reviewed-by: default avatarIdo Schimmel <idosch@mellanox.com>
Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 83930cd7
...@@ -3124,9 +3124,7 @@ mlxsw_sp_rif_should_config(struct mlxsw_sp_rif *rif, struct net_device *dev, ...@@ -3124,9 +3124,7 @@ mlxsw_sp_rif_should_config(struct mlxsw_sp_rif *rif, struct net_device *dev,
switch (event) { switch (event) {
case NETDEV_UP: case NETDEV_UP:
if (!rif) return rif == NULL;
return true;
return false;
case NETDEV_DOWN: case NETDEV_DOWN:
idev = __in_dev_get_rtnl(dev); idev = __in_dev_get_rtnl(dev);
if (idev && idev->ifa_list) if (idev && idev->ifa_list)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment