linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mtd: nand: fixup 1/0 vs. true/false
@ 2012-05-03 22:30 Brian Norris
  2012-05-04  7:55 ` Artem Bityutskiy
  0 siblings, 1 reply; 2+ messages in thread
From: Brian Norris @ 2012-05-03 22:30 UTC (permalink / raw)
  To: Artem Bityutskiy; +Cc: Mike Dunn, Brian Norris, linux-mtd, Shmulik Ladkani

The 'oob_required' argument is an int, according to the boolean style used in
nand_base.c, so we should use 1 and 0 instead of true and false.

Thanks Mike for spotting this.

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Cc: Mike Dunn <mikedunn@newsguy.com>
Cc: Shmulik Ladkani <shmulik.ladkani@gmail.com>
---
 drivers/mtd/nand/bcm_umi_nand.c        |    2 +-
 drivers/mtd/nand/docg4.c               |    4 ++--
 drivers/mtd/nand/gpmi-nand/gpmi-nand.c |    2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/mtd/nand/bcm_umi_nand.c b/drivers/mtd/nand/bcm_umi_nand.c
index c6d691a..c855e7c 100644
--- a/drivers/mtd/nand/bcm_umi_nand.c
+++ b/drivers/mtd/nand/bcm_umi_nand.c
@@ -341,7 +341,7 @@ static int bcm_umi_nand_verify_buf(struct mtd_info *mtd, const u_char * buf,
 	 * for MLC parts which may have permanently stuck bits.
 	 */
 	struct nand_chip *chip = mtd->priv;
-	int ret = chip->ecc.read_page(mtd, chip, readbackbuf, false, 0);
+	int ret = chip->ecc.read_page(mtd, chip, readbackbuf, 0, 0);
 	if (ret < 0)
 		return -EFAULT;
 	else {
diff --git a/drivers/mtd/nand/docg4.c b/drivers/mtd/nand/docg4.c
index 16221b2..1f8485d 100644
--- a/drivers/mtd/nand/docg4.c
+++ b/drivers/mtd/nand/docg4.c
@@ -1003,7 +1003,7 @@ static int __init read_factory_bbt(struct mtd_info *mtd)
 		return -ENOMEM;
 
 	read_page_prologue(mtd, g4_addr);
-	status = docg4_read_page(mtd, nand, buf, false, DOCG4_FACTORY_BBT_PAGE);
+	status = docg4_read_page(mtd, nand, buf, 0, DOCG4_FACTORY_BBT_PAGE);
 	if (status)
 		goto exit;
 
@@ -1080,7 +1080,7 @@ static int docg4_block_markbad(struct mtd_info *mtd, loff_t ofs)
 
 	/* write first page of block */
 	write_page_prologue(mtd, g4_addr);
-	docg4_write_page(mtd, nand, buf, true);
+	docg4_write_page(mtd, nand, buf, 1);
 	ret = pageprog(mtd);
 	if (!ret)
 		mtd->ecc_stats.badblocks++;
diff --git a/drivers/mtd/nand/gpmi-nand/gpmi-nand.c b/drivers/mtd/nand/gpmi-nand/gpmi-nand.c
index 805bcf3..dcf4152 100644
--- a/drivers/mtd/nand/gpmi-nand/gpmi-nand.c
+++ b/drivers/mtd/nand/gpmi-nand/gpmi-nand.c
@@ -1311,7 +1311,7 @@ static int mx23_write_transcription_stamp(struct gpmi_nand_data *this)
 		/* Write the first page of the current stride. */
 		dev_dbg(dev, "Writing an NCB fingerprint in page 0x%x\n", page);
 		chip->cmdfunc(mtd, NAND_CMD_SEQIN, 0x00, page);
-		chip->ecc.write_page_raw(mtd, chip, buffer, false);
+		chip->ecc.write_page_raw(mtd, chip, buffer, 0);
 		chip->cmdfunc(mtd, NAND_CMD_PAGEPROG, -1, -1);
 
 		/* Wait for the write to finish. */
-- 
1.7.5.4.2.g519b1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] mtd: nand: fixup 1/0 vs. true/false
  2012-05-03 22:30 [PATCH] mtd: nand: fixup 1/0 vs. true/false Brian Norris
@ 2012-05-04  7:55 ` Artem Bityutskiy
  0 siblings, 0 replies; 2+ messages in thread
From: Artem Bityutskiy @ 2012-05-04  7:55 UTC (permalink / raw)
  To: Brian Norris; +Cc: Mike Dunn, linux-mtd, Shmulik Ladkani

[-- Attachment #1: Type: text/plain, Size: 316 bytes --]

On Thu, 2012-05-03 at 15:30 -0700, Brian Norris wrote:
> The 'oob_required' argument is an int, according to the boolean style used in
> nand_base.c, so we should use 1 and 0 instead of true and false.
> 
> Thanks Mike for spotting this.

Pushed to l2-mtd.git, thanks!

-- 
Best Regards,
Artem Bityutskiy

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-05-04  7:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-03 22:30 [PATCH] mtd: nand: fixup 1/0 vs. true/false Brian Norris
2012-05-04  7:55 ` Artem Bityutskiy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).