mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-07 13:57:54 -04:00
net/mlx5: DR, Fix dumping of legacy modify_hdr in debug dump
The steering dump parser expects to see 0 as rewrite num of actions in case pattern/args aren't supported - parsing of legacy modify header is based on this assumption. Fix this to align to parser's expectation. Signed-off-by: Yevgeny Kliteynik <kliteyn@nvidia.com> Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
This commit is contained in:
committed by
Saeed Mahameed
parent
e315e7b83a
commit
075056005d
@@ -153,13 +153,15 @@ dr_dump_rule_action_mem(struct seq_file *file, const u64 rule_id,
|
||||
DR_DUMP_REC_TYPE_ACTION_MODIFY_HDR, action_id,
|
||||
rule_id, action->rewrite->index,
|
||||
action->rewrite->single_action_opt,
|
||||
action->rewrite->num_of_actions,
|
||||
ptrn_arg ? action->rewrite->num_of_actions : 0,
|
||||
ptrn_arg ? ptrn->index : 0,
|
||||
ptrn_arg ? mlx5dr_arg_get_obj_id(arg) : 0);
|
||||
|
||||
for (i = 0; i < action->rewrite->num_of_actions; i++) {
|
||||
seq_printf(file, ",0x%016llx",
|
||||
be64_to_cpu(((__be64 *)rewrite_data)[i]));
|
||||
if (ptrn_arg) {
|
||||
for (i = 0; i < action->rewrite->num_of_actions; i++) {
|
||||
seq_printf(file, ",0x%016llx",
|
||||
be64_to_cpu(((__be64 *)rewrite_data)[i]));
|
||||
}
|
||||
}
|
||||
|
||||
seq_puts(file, "\n");
|
||||
|
||||
Reference in New Issue
Block a user