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]
Message-ID: <1577172735-18869-6-git-send-email-zhengbin13@huawei.com>
Date:   Tue, 24 Dec 2019 15:32:14 +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 5/6] mmc: davinci: use true,false for bool variable

Fixes coccicheck warning:

drivers/mmc/host/davinci_mmc.c:480:1-13: WARNING: Assignment of 0/1 to bool variable
drivers/mmc/host/davinci_mmc.c:607:1-13: WARNING: Assignment of 0/1 to bool variable
drivers/mmc/host/davinci_mmc.c:1270:3-16: 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/davinci_mmc.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/davinci_mmc.c b/drivers/mmc/host/davinci_mmc.c
index f01fecd..fe94907 100644
--- a/drivers/mmc/host/davinci_mmc.c
+++ b/drivers/mmc/host/davinci_mmc.c
@@ -477,7 +477,7 @@ static int mmc_davinci_start_dma_transfer(struct mmc_davinci_host *host,
 		}
 	}

-	host->do_dma = 1;
+	host->do_dma = true;
 	ret = mmc_davinci_send_dma_request(host, data);

 	return ret;
@@ -604,7 +604,7 @@ static void mmc_davinci_request(struct mmc_host *mmc, struct mmc_request *req)
 		return;
 	}

-	host->do_dma = 0;
+	host->do_dma = false;
 	mmc_davinci_prepare_data(host, req);
 	mmc_davinci_start_command(host, req->cmd);
 }
@@ -1267,7 +1267,7 @@ static int davinci_mmcsd_probe(struct platform_device *pdev)
 		if (ret == -EPROBE_DEFER)
 			goto dma_probe_defer;
 		else if (ret)
-			host->use_dma = 0;
+			host->use_dma = false;
 	}

 	mmc->caps |= MMC_CAP_WAIT_WHILE_BUSY;
--
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ