[v2,1/5] net/mlx5/hws: fix alias_rtc_0 print location in debug dump

Message ID 20230202160259.834707-1-hamdani@nvidia.com (mailing list archive)
State Accepted, archived
Delegated to: Raslan Darawsheh
Headers
Series [v2,1/5] net/mlx5/hws: fix alias_rtc_0 print location in debug dump |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/iol-testing warning apply patch failure

Commit Message

Hamdan Igbaria Feb. 2, 2023, 4:02 p.m. UTC
  Fix alias_rtc_0 print location in debug dump, move it to
the end of matcher dumped info instead of the middle, to
keep the dump compatibility.

Fixes: dd2845361a58 ("net/mlx5/hws: add debug details for cross gvmi")
Signed-off-by: Hamdan Igbaria <hamdani@nvidia.com>
---
 drivers/net/mlx5/hws/mlx5dr_debug.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
  

Comments

Matan Azrad Feb. 12, 2023, 11:50 a.m. UTC | #1
From: Hamdan Igbaria
> Fix alias_rtc_0 print location in debug dump, move it to the end of matcher
> dumped info instead of the middle, to keep the dump compatibility.
> 
> Fixes: dd2845361a58 ("net/mlx5/hws: add debug details for cross gvmi")
> Signed-off-by: Hamdan Igbaria <hamdani@nvidia.com>
> ---
>  drivers/net/mlx5/hws/mlx5dr_debug.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)

Looks ok to me.

Series-acked-by: Matan Azrad <matan@nvidia.com>
  
Raslan Darawsheh Feb. 14, 2023, 8:28 a.m. UTC | #2
Hi,

> -----Original Message-----
> From: Hamdan Igbaria <hamdani@nvidia.com>
> Sent: Thursday, February 2, 2023 6:03 PM
> To: Hamdan Igbaria <hamdani@nvidia.com>; Slava Ovsiienko
> <viacheslavo@nvidia.com>; NBU-Contact-Thomas Monjalon (EXTERNAL)
> <thomas@monjalon.net>; Suanming Mou <suanmingm@nvidia.com>;
> Matan Azrad <matan@nvidia.com>
> Cc: dev@dpdk.org; Ori Kam <orika@nvidia.com>; Alex Vesker
> <valex@nvidia.com>
> Subject: [v2 1/5] net/mlx5/hws: fix alias_rtc_0 print location in debug dump
> 
> Fix alias_rtc_0 print location in debug dump, move it to the end of matcher
> dumped info instead of the middle, to keep the dump compatibility.
> 
> Fixes: dd2845361a58 ("net/mlx5/hws: add debug details for cross gvmi")
> Signed-off-by: Hamdan Igbaria <hamdani@nvidia.com>

Series applied to next-net-mlx,

Kindest regards,
Raslan Darawsheh
  

Patch

diff --git a/drivers/net/mlx5/hws/mlx5dr_debug.c b/drivers/net/mlx5/hws/mlx5dr_debug.c
index 0815327b18..4bbdb767ee 100644
--- a/drivers/net/mlx5/hws/mlx5dr_debug.c
+++ b/drivers/net/mlx5/hws/mlx5dr_debug.c
@@ -208,13 +208,11 @@  static int mlx5dr_debug_dump_matcher(FILE *f, struct mlx5dr_matcher *matcher)
 		ste_1 = NULL;
 	}
 
-	ret = fprintf(f, ",%d,%d,%d,%d,%d",
+	ret = fprintf(f, ",%d,%d,%d,%d",
 		      matcher->match_ste.rtc_0 ? matcher->match_ste.rtc_0->id : 0,
 		      ste_0 ? (int)ste_0->id : -1,
 		      matcher->match_ste.rtc_1 ? matcher->match_ste.rtc_1->id : 0,
-		      ste_1 ? (int)ste_1->id : -1,
-		      is_shared && !is_root ?
-		      matcher->match_ste.aliased_rtc_0->id : 0);
+		      ste_1 ? (int)ste_1->id : -1);
 	if (ret < 0)
 		goto out_err;
 
@@ -229,11 +227,13 @@  static int mlx5dr_debug_dump_matcher(FILE *f, struct mlx5dr_matcher *matcher)
 		ste_1 = NULL;
 	}
 
-	ret = fprintf(f, ",%d,%d,%d,%d\n",
+	ret = fprintf(f, ",%d,%d,%d,%d,%d\n",
 		      matcher->action_ste.rtc_0 ? matcher->action_ste.rtc_0->id : 0,
 		      ste_0 ? (int)ste_0->id : -1,
 		      matcher->action_ste.rtc_1 ? matcher->action_ste.rtc_1->id : 0,
-		      ste_1 ? (int)ste_1->id : -1);
+		      ste_1 ? (int)ste_1->id : -1,
+		      is_shared && !is_root ?
+		      matcher->match_ste.aliased_rtc_0->id : 0);
 	if (ret < 0)
 		goto out_err;