[PATCH -next 2/2] RDMA/irdma: Simplify bool conversion
From: Jiapeng Chong
Date: Thu Dec 04 2025 - 04:25:03 EST
./drivers/infiniband/hw/irdma/uk.c:1412:6-11: WARNING: conversion to bool not needed here.
Reported-by: Abaci Robot <abaci@xxxxxxxxxxxxxxxxx>
Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=27521
Signed-off-by: Jiapeng Chong <jiapeng.chong@xxxxxxxxxxxxxxxxx>
---
drivers/infiniband/hw/irdma/uk.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/infiniband/hw/irdma/uk.c b/drivers/infiniband/hw/irdma/uk.c
index f0846b800913..91669326d464 100644
--- a/drivers/infiniband/hw/irdma/uk.c
+++ b/drivers/infiniband/hw/irdma/uk.c
@@ -1408,8 +1408,7 @@ int irdma_uk_cq_poll_cmpl(struct irdma_cq_uk *cq,
* from SW for all unprocessed WQEs. For GEN3 and beyond
* FW will generate/flush these CQEs so move to the next CQE
*/
- move_cq_head = qp->uk_attrs->hw_rev <= IRDMA_GEN_2 ?
- false : true;
+ move_cq_head = qp->uk_attrs->hw_rev > IRDMA_GEN_2;
}
if (move_cq_head) {
--
2.43.7