Commit f34b4aac authored by Nogah Frankel's avatar Nogah Frankel Committed by David S. Miller

net: sch: red: Change the name of the stats struct to be generic

Change the name of the stats struct to be generic, so it could be used for
other qdisc offload, that will be added in the next patches.
Signed-off-by: default avatarNogah Frankel <nogahf@mellanox.com>
Reviewed-by: default avatarYuval Mintz <yuvalm@mellanox.com>
Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 371b437a
...@@ -229,7 +229,7 @@ static int ...@@ -229,7 +229,7 @@ static int
mlxsw_sp_qdisc_get_red_stats(struct mlxsw_sp_port *mlxsw_sp_port, u32 handle, mlxsw_sp_qdisc_get_red_stats(struct mlxsw_sp_port *mlxsw_sp_port, u32 handle,
struct mlxsw_sp_qdisc *mlxsw_sp_qdisc, struct mlxsw_sp_qdisc *mlxsw_sp_qdisc,
int tclass_num, int tclass_num,
struct tc_red_qopt_offload_stats *res) struct tc_qopt_offload_stats *res)
{ {
u64 tx_bytes, tx_packets, overlimits, drops; u64 tx_bytes, tx_packets, overlimits, drops;
struct mlxsw_sp_port_xstats *xstats; struct mlxsw_sp_port_xstats *xstats;
......
...@@ -731,6 +731,11 @@ struct tc_cookie { ...@@ -731,6 +731,11 @@ struct tc_cookie {
u32 len; u32 len;
}; };
struct tc_qopt_offload_stats {
struct gnet_stats_basic_packed *bstats;
struct gnet_stats_queue *qstats;
};
enum tc_red_command { enum tc_red_command {
TC_RED_REPLACE, TC_RED_REPLACE,
TC_RED_DESTROY, TC_RED_DESTROY,
...@@ -744,10 +749,6 @@ struct tc_red_qopt_offload_params { ...@@ -744,10 +749,6 @@ struct tc_red_qopt_offload_params {
u32 probability; u32 probability;
bool is_ecn; bool is_ecn;
}; };
struct tc_red_qopt_offload_stats {
struct gnet_stats_basic_packed *bstats;
struct gnet_stats_queue *qstats;
};
struct tc_red_qopt_offload { struct tc_red_qopt_offload {
enum tc_red_command command; enum tc_red_command command;
...@@ -755,7 +756,7 @@ struct tc_red_qopt_offload { ...@@ -755,7 +756,7 @@ struct tc_red_qopt_offload {
u32 parent; u32 parent;
union { union {
struct tc_red_qopt_offload_params set; struct tc_red_qopt_offload_params set;
struct tc_red_qopt_offload_stats stats; struct tc_qopt_offload_stats stats;
struct red_stats *xstats; struct red_stats *xstats;
}; };
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment