1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2 #ifndef __LINUX_GEN_STATS_H
3 #define __LINUX_GEN_STATS_H
5 #include <linux/types.h>
18 #define TCA_STATS_MAX (__TCA_STATS_MAX - 1)
21 * struct gnet_stats_basic - byte/packet throughput statistics
22 * @bytes: number of seen bytes
23 * @packets: number of seen packets
25 struct gnet_stats_basic {
31 * struct gnet_stats_rate_est - rate estimator
32 * @bps: current byte rate
33 * @pps: current packet rate
35 struct gnet_stats_rate_est {
41 * struct gnet_stats_rate_est64 - rate estimator
42 * @bps: current byte rate
43 * @pps: current packet rate
45 struct gnet_stats_rate_est64 {
51 * struct gnet_stats_queue - queuing statistics
53 * @backlog: backlog size of queue
54 * @drops: number of dropped packets
55 * @requeues: number of requeues
56 * @overlimits: number of enqueues over the limit
58 struct gnet_stats_queue {
67 * struct gnet_estimator - rate estimator configuration
68 * @interval: sampling period
69 * @ewma_log: the log of measurement window weight
71 struct gnet_estimator {
73 unsigned char ewma_log;
77 #endif /* __LINUX_GEN_STATS_H */