tc: flower: Fix incorrect error msg about eth type
addattr16 may return an error about the nl msg size
but not about incorrect eth type.
Fixes: 488b41d020 ("tc: flower no need to specify the ethertype")
Signed-off-by: Roi Dayan <roid@mellanox.com>
Reviewed-by: Paul Blakey <paulb@mellanox.com>
This commit is contained in:
parent
c85609b25f
commit
00697ca19a
|
|
@ -530,11 +530,8 @@ parse_done:
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
ret = addattr16(n, MAX_MSG, TCA_FLOWER_KEY_ETH_TYPE, eth_type);
|
ret = addattr16(n, MAX_MSG, TCA_FLOWER_KEY_ETH_TYPE, eth_type);
|
||||||
if (ret) {
|
if (ret)
|
||||||
fprintf(stderr, "Illegal \"eth_type\"(0x%x)\n",
|
return ret;
|
||||||
ntohs(eth_type));
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
tail->rta_len = (((void *)n)+n->nlmsg_len) - (void *)tail;
|
tail->rta_len = (((void *)n)+n->nlmsg_len) - (void *)tail;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue