Skip to contentSkip to conversation

net/mlx5: fix invalid entry assert

PATCH In review Suanming Mou 3 participants 3 messages Nov 6, 2020 – Nov 9, 2020 Network drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net/mlx5: fix invalid entry assert

The entry variable assert in the mlx5_hlist_register() function is not correct. Remove the invalid entry variable.

Fixes e69a59227db0 ("net/mlx5: support concurrent access for hash list")
---
 drivers/net/mlx5/mlx5_utils.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/mlx5/mlx5_utils.c +1 -1
index 13590dd..9889437 100644
@@ -132,7 +132,7 @@ struct mlx5_hlist_entry*
 	struct mlx5_hlist_entry *entry;
 	uint32_t prev_gen_cnt = 0;
 
-	MLX5_ASSERT(h && entry);
+	MLX5_ASSERT(h);
 	/* Use write lock directly for write-most list. */
 	if (!h->write_most) {
 		prev_gen_cnt = __atomic_load_n(&h->gen_cnt, __ATOMIC_ACQUIRE);
Signature · 1 line
1.8.3.1
Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines

-----Original Message-----
From: Suanming Mou <[email protected]>
Sent: Friday, November 6, 2020 5:02
To: Slava Ovsiienko <[email protected]>; Matan Azrad <[email protected]>
Cc: Raslan Darawsheh <[email protected]>; [email protected]
Subject: [PATCH] net/mlx5: fix invalid entry assert

Quoted 6 lines

The entry variable assert in the mlx5_hlist_register() function is not correct. Remove the invalid entry variable.

Fixes e69a59227db0 ("net/mlx5: support concurrent access for hash list")
Quoted 20 lines
---
 drivers/net/mlx5/mlx5_utils.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/mlx5/mlx5_utils.c index renamed from drivers/net/mlx5/mlx5_utils.c +0 -0

13590dd..9889437 100644

drivers/net/mlx5/mlx5_utils.c +1 -1
@@ -132,7 +132,7 @@ struct mlx5_hlist_entry*
 	struct mlx5_hlist_entry *entry;
 	uint32_t prev_gen_cnt = 0;
 
-	MLX5_ASSERT(h && entry);
+	MLX5_ASSERT(h);
 	/* Use write lock directly for write-most list. */
 	if (!h->write_most) {
 		prev_gen_cnt = __atomic_load_n(&h->gen_cnt,

__ATOMIC_ACQUIRE);
--
1.8.3.1

#2 lore raw
In reply to Suanming Mou

Hi,

Quoted 8 lines

-----Original Message-----
From: Suanming Mou <[email protected]>
Sent: Friday, November 6, 2020 5:02 AM
To: Slava Ovsiienko <[email protected]>; Matan Azrad <[email protected]>
Cc: Raslan Darawsheh <[email protected]>; [email protected]
Subject: [PATCH] net/mlx5: fix invalid entry assert

Quoted 7 lines

The entry variable assert in the mlx5_hlist_register() function is not correct. Remove the invalid entry variable.

Fixes e69a59227db0 ("net/mlx5: support concurrent access for hash list")

---

Patch applied to next-net-mlx,

Kindest regards,
Raslan Darawsheh