Skip to contentSkip to conversation

scsi: csiostor: Assign boolean values to a bool variable

PATCH Applied Jiapeng Chong 2 participants 2 messages Mar 9, 2021 – Mar 19, 2021

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 scsi: csiostor: Assign boolean values to a bool variable

Fix the following coccicheck warnings:

./drivers/scsi/csiostor/csio_scsi.c:150:9-10: WARNING: return of 0/1 in function 'csio_scsi_itnexus_loss_error' with return type bool.

---
 drivers/scsi/csiostor/csio_scsi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/scsi/csiostor/csio_scsi.c +2 -2
index 55e74da..56b9ad0 100644
@@ -147,9 +147,9 @@ static int csio_do_abrt_cls(struct csio_hw *,
 	case FW_ERR_RDEV_LOST:
 	case FW_ERR_RDEV_LOGO:
 	case FW_ERR_RDEV_IMPL_LOGO:
-		return 1;
+		return true;
 	}
-	return 0;
+	return false;
 }
 
 /*
Signature · 6 lines
1.8.3.1

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#1 lore raw
Quoted 4 lines · Jiapeng Chong

Fix the following coccicheck warnings:

./drivers/scsi/csiostor/csio_scsi.c:150:9-10: WARNING: return of 0/1 in function 'csio_scsi_itnexus_loss_error' with return type bool.

Applied to 5.13/scsi-queue, thanks!

[1/1] scsi: csiostor: Assign boolean values to a bool variable

      https://git.kernel.org/mkp/scsi/c/2ed0fc2b9a79
Signature · 1 line
Martin K. Petersen	Oracle Linux Engineering