aboutsummaryrefslogtreecommitdiff
path: root/include/net/pkt_cls.h
diff options
context:
space:
mode:
authorJakub Kicinski <jakub.kicinski@netronome.com>2018-11-19 15:21:43 -0800
committerDavid S. Miller <davem@davemloft.net>2018-11-19 18:53:46 -0800
commite49efd5288bd6670cc05860fe04ef611c3887399 (patch)
treeb080eea5df364d9616d79ec4acda64707acfdd1c /include/net/pkt_cls.h
parent890d8d23ec3c9eca847be0593c0cf5f650b97271 (diff)
net: sched: gred: support reporting stats from offloads
Allow drivers which offload GRED to report back statistics. Since A lot of GRED stats is fairly ad hoc in nature pass to drivers the standard struct gnet_stats_basic/gnet_stats_queue pairs, and untangle the values in the core. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by: John Hurley <john.hurley@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/pkt_cls.h')
-rw-r--r--include/net/pkt_cls.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/net/pkt_cls.h b/include/net/pkt_cls.h
index c9198797aaed..d0e9a8091426 100644
--- a/include/net/pkt_cls.h
+++ b/include/net/pkt_cls.h
@@ -871,6 +871,7 @@ struct tc_red_qopt_offload {
enum tc_gred_command {
TC_GRED_REPLACE,
TC_GRED_DESTROY,
+ TC_GRED_STATS,
};
struct tc_gred_vq_qopt_offload_params {
@@ -895,12 +896,19 @@ struct tc_gred_qopt_offload_params {
struct tc_gred_vq_qopt_offload_params tab[MAX_DPs];
};
+struct tc_gred_qopt_offload_stats {
+ struct gnet_stats_basic_packed bstats[MAX_DPs];
+ struct gnet_stats_queue qstats[MAX_DPs];
+ struct red_stats *xstats[MAX_DPs];
+};
+
struct tc_gred_qopt_offload {
enum tc_gred_command command;
u32 handle;
u32 parent;
union {
struct tc_gred_qopt_offload_params set;
+ struct tc_gred_qopt_offload_stats stats;
};
};