From 4399f2d109b54e02fde8f3d0772c3fdf3bd1c18b Mon Sep 17 00:00:00 2001 From: Gleb Chesnokov Date: Mon, 20 Jun 2022 16:35:11 +0300 Subject: [PATCH] scst_lib: Simplify redundant boolean expression This was detected by Coverity. --- scst/src/scst_lib.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scst/src/scst_lib.c b/scst/src/scst_lib.c index 603e10ed0..37318c1c2 100644 --- a/scst/src/scst_lib.c +++ b/scst/src/scst_lib.c @@ -8073,8 +8073,7 @@ scst_alloc_passthrough_request(struct request_queue *q, int rw, gfp_t gfp_mask) return blk_get_request(q, rw == READ ? REQ_OP_SCSI_IN : REQ_OP_SCSI_OUT, scst_gfp_mask_to_flags(gfp_mask)); #else - return blk_mq_alloc_request(q, rw == READ ? REQ_OP_DRV_IN : - rw == READ ? REQ_OP_DRV_IN : REQ_OP_DRV_OUT, + return blk_mq_alloc_request(q, rw == READ ? REQ_OP_DRV_IN : REQ_OP_DRV_OUT, scst_gfp_mask_to_flags(gfp_mask)); #endif }