lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 24 Dec 2019 15:32:13 +0800
From:   zhengbin <zhengbin13@...wei.com>
To:     <ulf.hansson@...aro.org>, <linux-mmc@...r.kernel.org>,
        <linux-kernel@...r.kernel.org>
CC:     <zhengbin13@...wei.com>
Subject: [PATCH 4/6] mmc: omap_hsmmc: use true,false for bool variable

Fixes coccicheck warning:

drivers/mmc/host/omap_hsmmc.c:294:3-22: WARNING: Assignment of 0/1 to bool variable
drivers/mmc/host/omap_hsmmc.c:303:3-22: WARNING: Assignment of 0/1 to bool variable
drivers/mmc/host/omap_hsmmc.c:1866:1-20: WARNING: Assignment of 0/1 to bool variable

Reported-by: Hulk Robot <hulkci@...wei.com>
Signed-off-by: zhengbin <zhengbin13@...wei.com>
---
 drivers/mmc/host/omap_hsmmc.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
index a379c45..ce2a929 100644
--- a/drivers/mmc/host/omap_hsmmc.c
+++ b/drivers/mmc/host/omap_hsmmc.c
@@ -291,7 +291,7 @@ static int omap_hsmmc_set_pbias(struct omap_hsmmc_host *host, bool power_on)
 				dev_err(host->dev, "pbias reg enable fail\n");
 				return ret;
 			}
-			host->pbias_enabled = 1;
+			host->pbias_enabled = true;
 		}
 	} else {
 		if (host->pbias_enabled == 1) {
@@ -300,7 +300,7 @@ static int omap_hsmmc_set_pbias(struct omap_hsmmc_host *host, bool power_on)
 				dev_err(host->dev, "pbias reg disable fail\n");
 				return ret;
 			}
-			host->pbias_enabled = 0;
+			host->pbias_enabled = false;
 		}
 	}

@@ -1863,7 +1863,7 @@ static int omap_hsmmc_probe(struct platform_device *pdev)
 	host->base	= base + pdata->reg_offset;
 	host->power_mode = MMC_POWER_OFF;
 	host->next_data.cookie = 1;
-	host->pbias_enabled = 0;
+	host->pbias_enabled = false;
 	host->vqmmc_enabled = 0;

 	platform_set_drvdata(pdev, host);
--
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ