From: Petr Machata Date: Mon, 31 Jul 2017 07:27:29 +0000 (+0200) Subject: mlxsw: spectrum_router: Clarify a piece of code X-Git-Tag: v4.14-rc1~130^2~417^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=56b8a9ed276bc1771deb4efd5f409749ababc961;p=platform%2Fkernel%2Flinux-exynos.git mlxsw: spectrum_router: Clarify a piece of code Prefer logical operator that expresses the intent to bitwise one that happens to give the same result. Signed-off-by: Petr Machata Reviewed-by: Ido Schimmel Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c index 600268c..c69efbd 100644 --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c @@ -1668,7 +1668,7 @@ mlxsw_sp_nexthop_group_refresh(struct mlxsw_sp *mlxsw_sp, for (i = 0; i < nh_grp->count; i++) { nh = &nh_grp->nexthops[i]; - if (nh->should_offload ^ nh->offloaded) { + if (nh->should_offload != nh->offloaded) { offload_change = true; if (nh->should_offload) nh->update = 1;