qdisc: print offload indication
Use the newly added TCA_HW_OFFLOAD indication from kernel to print a consistent 'offloaded' message to user when listing qdiscs. Signed-off-by: Yuval Mintz <yuvalm@mellanox.com> Reviewed-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
This commit is contained in:
parent
afdf9277eb
commit
b97c6fa71d
|
|
@ -266,6 +266,10 @@ int print_qdisc(const struct sockaddr_nl *who,
|
||||||
if (t->tcm_info != 1)
|
if (t->tcm_info != 1)
|
||||||
print_uint(PRINT_ANY, "refcnt", "refcnt %u ", t->tcm_info);
|
print_uint(PRINT_ANY, "refcnt", "refcnt %u ", t->tcm_info);
|
||||||
|
|
||||||
|
if (tb[TCA_HW_OFFLOAD] &&
|
||||||
|
(rta_getattr_u8(tb[TCA_HW_OFFLOAD])))
|
||||||
|
print_bool(PRINT_ANY, "offloaded", "offloaded ", true);
|
||||||
|
|
||||||
/* pfifo_fast is generic enough to warrant the hardcoding --JHS */
|
/* pfifo_fast is generic enough to warrant the hardcoding --JHS */
|
||||||
if (strcmp("pfifo_fast", RTA_DATA(tb[TCA_KIND])) == 0)
|
if (strcmp("pfifo_fast", RTA_DATA(tb[TCA_KIND])) == 0)
|
||||||
q = get_qdisc_kind("prio");
|
q = get_qdisc_kind("prio");
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue