aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/ufs/ufs-qcom.h
diff options
context:
space:
mode:
authorBart Van Assche <bvanassche@acm.org>2022-04-19 15:57:47 -0700
committerMartin K. Petersen <martin.petersen@oracle.com>2022-04-25 23:23:02 -0400
commita858af9a9e01972c33f61036a3de6f707184e51b (patch)
treebd94e34bc36e0e31d58912c317537bbe3d9ca027 /drivers/scsi/ufs/ufs-qcom.h
parentscsi: ufs: Remove superfluous boolean conversions (diff)
downloadlinux-dev-a858af9a9e01972c33f61036a3de6f707184e51b.tar.xz
linux-dev-a858af9a9e01972c33f61036a3de6f707184e51b.zip
scsi: ufs: Simplify statements that return a boolean
Convert "if (expr) return true; else return false;" into "return expr;" if either 'expr' is a boolean expression or the return type of the function is 'bool'. Link: https://lore.kernel.org/r/20220419225811.4127248-5-bvanassche@acm.org Tested-by: Bean Huo <beanhuo@micron.com> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: Keoseong Park <keosung.park@samsung.com> Reviewed-by: Bean Huo <beanhuo@micron.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/ufs/ufs-qcom.h')
-rw-r--r--drivers/scsi/ufs/ufs-qcom.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/scsi/ufs/ufs-qcom.h b/drivers/scsi/ufs/ufs-qcom.h
index 8208e3a3ef59..51570224a6e2 100644
--- a/drivers/scsi/ufs/ufs-qcom.h
+++ b/drivers/scsi/ufs/ufs-qcom.h
@@ -239,10 +239,7 @@ int ufs_qcom_testbus_config(struct ufs_qcom_host *host);
static inline bool ufs_qcom_cap_qunipro(struct ufs_qcom_host *host)
{
- if (host->caps & UFS_QCOM_CAP_QUNIPRO)
- return true;
- else
- return false;
+ return host->caps & UFS_QCOM_CAP_QUNIPRO;
}
/* ufs-qcom-ice.c */