Commit 19d04a94 authored by Lu Wei's avatar Lu Wei Committed by David S. Miller

net: microchip: sparx5: Fix return value in sparx5_tc_setup_qdisc_ets()

Function sparx5_tc_setup_qdisc_ets() always returns negative value
because it return -EOPNOTSUPP in the end. This patch returns the
rersult of sparx5_tc_ets_add() and sparx5_tc_ets_del() directly.

Fixes: 21122542 ("net: microchip: sparx5: add support for offloading ets qdisc")
Signed-off-by: default avatarLu Wei <luwei32@huawei.com>
Reviewed-by: default avatarDaniel Machon <daniel.machon@microchip.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 9ab000d9
......@@ -90,13 +90,10 @@ static int sparx5_tc_setup_qdisc_ets(struct net_device *ndev,
}
}
sparx5_tc_ets_add(port, params);
break;
return sparx5_tc_ets_add(port, params);
case TC_ETS_DESTROY:
sparx5_tc_ets_del(port);
break;
return sparx5_tc_ets_del(port);
case TC_ETS_GRAFT:
return -EOPNOTSUPP;
......
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