projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net: sched: move the can_offload check from binding phase to rule insertion phase
[linux-2.6-microblaze.git]
/
drivers
/
net
/
ethernet
/
mellanox
/
mlx5
/
core
/
en_main.c
diff --git
a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
index
560b208
..
28ae00b
100644
(file)
--- a/
drivers/net/ethernet/mellanox/mlx5/core/en_main.c
+++ b/
drivers/net/ethernet/mellanox/mlx5/core/en_main.c
@@
-3106,6
+3106,9
@@
int mlx5e_setup_tc_block_cb(enum tc_setup_type type, void *type_data,
{
struct mlx5e_priv *priv = cb_priv;
{
struct mlx5e_priv *priv = cb_priv;
+ if (!tc_can_offload(priv->netdev))
+ return -EOPNOTSUPP;
+
switch (type) {
case TC_SETUP_CLSFLOWER:
return mlx5e_setup_tc_cls_flower(priv, type_data);
switch (type) {
case TC_SETUP_CLSFLOWER:
return mlx5e_setup_tc_cls_flower(priv, type_data);