From: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Date: Tue, 5 Jul 2022 22:36:26 +0200
Subject: qed: Use bitmap_empty()
Patch-mainline: v6.0-rc1
Git-commit: 7ed5f2454acf8ebc126ff4d541832e8d2c28c0a0
References: jsc#PED-1526
Use bitmap_empty() instead of hand-writing it.
It is less verbose and it improves the semantic.
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Link: https://lore.kernel.org/r/78713a72414b99f673c3a9ec0519bb41c080935a.1657053343.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Acked-by: Thomas Bogendoerfer <tbogendoerfer@suse.de>
---
drivers/net/ethernet/qlogic/qed/qed_rdma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/net/ethernet/qlogic/qed/qed_rdma.c
+++ b/drivers/net/ethernet/qlogic/qed/qed_rdma.c
@@ -106,7 +106,7 @@ int qed_bmap_test_id(struct qed_hwfn *p_
static bool qed_bmap_is_empty(struct qed_bmap *bmap)
{
- return bmap->max_count == find_first_bit(bmap->bitmap, bmap->max_count);
+ return bitmap_empty(bmap->bitmap, bmap->max_count);
}
static u32 qed_rdma_get_sb_id(void *p_hwfn, u32 rel_sb_id)