From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Hemminger Subject: Re: [Cake] [PATCH iproute2-next v3] Add support for cake qdisc Date: Tue, 24 Apr 2018 07:45:52 -0700 Message-ID: <20180424074552.397564a5@xeon-e3> References: <20180424114407.5939-2-toke@toke.dk> <20180424123046.21247-1-toke@toke.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: netdev@vger.kernel.org, cake@lists.bufferbloat.net To: Toke =?UTF-8?B?SMO4aWxhbmQtSsO4cmdlbnNlbg==?= Return-path: Received: from mail-pg0-f47.google.com ([74.125.83.47]:34771 "EHLO mail-pg0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750916AbeDXOpy (ORCPT ); Tue, 24 Apr 2018 10:45:54 -0400 Received: by mail-pg0-f47.google.com with SMTP id p10so11046179pgn.1 for ; Tue, 24 Apr 2018 07:45:54 -0700 (PDT) In-Reply-To: <20180424123046.21247-1-toke@toke.dk> Sender: netdev-owner@vger.kernel.org List-ID: On Tue, 24 Apr 2018 14:30:46 +0200 Toke H=C3=B8iland-J=C3=B8rgensen wrote: > +static void cake_print_json_tin(struct tc_cake_tin_stats *tst, uint vers= ion) > +{ > + open_json_object(NULL); > + print_uint(PRINT_JSON, "threshold_rate", NULL, tst->threshold_rate); > + print_uint(PRINT_JSON, "target", NULL, tst->target_us); > + print_uint(PRINT_JSON, "interval", NULL, tst->interval_us); > + print_uint(PRINT_JSON, "peak_delay", NULL, tst->peak_delay_us); > + print_uint(PRINT_JSON, "average_delay", NULL, tst->avge_delay_us); > + print_uint(PRINT_JSON, "base_delay", NULL, tst->base_delay_us); > + print_uint(PRINT_JSON, "sent_packets", NULL, tst->sent.packets); > + print_uint(PRINT_JSON, "sent_bytes", NULL, tst->sent.bytes); > + print_uint(PRINT_JSON, "way_indirect_hits", NULL, tst->way_indirect_hit= s); > + print_uint(PRINT_JSON, "way_misses", NULL, tst->way_misses); > + print_uint(PRINT_JSON, "way_collisions", NULL, tst->way_collisions); > + print_uint(PRINT_JSON, "drops", NULL, tst->dropped.packets); > + print_uint(PRINT_JSON, "ecn_mark", NULL, tst->ecn_marked.packets); > + print_uint(PRINT_JSON, "ack_drops", NULL, tst->ack_drops.packets); > + print_uint(PRINT_JSON, "sparse_flows", NULL, tst->sparse_flows); > + print_uint(PRINT_JSON, "bulk_flows", NULL, tst->bulk_flows); > + print_uint(PRINT_JSON, "unresponsive_flows", NULL, tst->unresponse_flow= s); > + print_uint(PRINT_JSON, "max_pkt_len", NULL, tst->max_skblen); > + if (version >=3D 0x102) > + print_uint(PRINT_JSON, "flow_quantum", NULL, tst->flow_quantum); Please don't version objects in netlink. That is not how netlink is supposed to be used.