Skip to contentSkip to conversation

NAND: Remove ONFI detection message to from bootup log

PATCH In review Stefan Roese 4 participants 4 messages May 8, 2012 – May 21, 2012

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

PATCH 1/1 NAND: Remove ONFI detection message to from bootup log

Without this patch, boot shows this messages upon NAND detection:

NAND: ONFI flash detected
ONFI param page 0 valid
ONFI flash detected
ONFI param page 0 valid
128 MiB

With this patch, its back to the U-Boot "standard":

NAND: 128 MiB

Tested on x600 (SPEAr600).

Cc Amit Virdi <[email protected]>
Cc Vipin Kumar <[email protected]>
Cc Scott Wood <[email protected]>
---
 drivers/mtd/nand/nand_base.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/mtd/nand/nand_base.c +3 -2
index bef79be..bfd668f 100644
@@ -2530,13 +2530,14 @@ static int nand_flash_detect_onfi(struct mtd_info *mtd, struct nand_chip *chip,
 		chip->read_byte(mtd) != 'F' || chip->read_byte(mtd) != 'I')
 		return 0;
 
-	printk(KERN_INFO "ONFI flash detected\n");
+	MTDDEBUG(MTD_DEBUG_LEVEL0, "ONFI flash detected\n");
 	chip->cmdfunc(mtd, NAND_CMD_PARAM, 0, -1);
 	for (i = 0; i < 3; i++) {
 		chip->read_buf(mtd, (uint8_t *)p, sizeof(*p));
 		if (onfi_crc16(ONFI_CRC_BASE, (uint8_t *)p, 254) ==
 				le16_to_cpu(p->crc)) {
-			printk(KERN_INFO "ONFI param page %d valid\n", i);
+			MTDDEBUG(MTD_DEBUG_LEVEL0,
+				 "ONFI param page %d valid\n", i);
 			break;
 		}
 	}
Signature · 1 line
1.7.10.1
#1 lore raw

PATCH 1/1 NAND: Remove ONFI detection message to from bootup log

Stefan,

Quoted 33 lines · Stefan Roese

Without this patch, boot shows this messages upon NAND detection:

NAND: ONFI flash detected
ONFI param page 0 valid
ONFI flash detected
ONFI param page 0 valid
128 MiB

With this patch, its back to the U-Boot "standard":

NAND: 128 MiB

Tested on x600 (SPEAr600).

Cc Amit Virdi<[email protected]>
Cc Vipin Kumar<[email protected]>
Cc Scott Wood<[email protected]>
---
  drivers/mtd/nand/nand_base.c |    5 +++--
  1 file changed, 3 insertions(+), 2 deletions(-)
drivers/mtd/nand/nand_base.c +1 -1
index bef79be..bfd668f 100644
@@ -2530,13 +2530,14 @@ static int nand_flash_detect_onfi(struct mtd_info *mtd, struct nand_chip *chip,
  		chip->read_byte(mtd) != 'F' || chip->read_byte(mtd) != 'I')
  		return 0;
 
-	printk(KERN_INFO "ONFI flash detected\n");
+	MTDDEBUG(MTD_DEBUG_LEVEL0, "ONFI flash detected\n");
  	chip->cmdfunc(mtd, NAND_CMD_PARAM, 0, -1);

drivers/mtd/nand/nand_base.c static int nand_flash_detect_onfi(struct mtd_info *mtd, struct nand_chip *chip, · line 2543

Quoted 10 lines
drivers/mtd/nand/nand_base.c +2 -1
  	for (i = 0; i<  3; i++) {
  		chip->read_buf(mtd, (uint8_t *)p, sizeof(*p));
  		if (onfi_crc16(ONFI_CRC_BASE, (uint8_t *)p, 254) ==
  				le16_to_cpu(p->crc)) {
-			printk(KERN_INFO "ONFI param page %d valid\n", i);
+			MTDDEBUG(MTD_DEBUG_LEVEL0,
+				 "ONFI param page %d valid\n", i);
  			break;
  		}
  	}

Regards
Amit Virdi

#2 lore raw
In reply to Stefan Roese
Quoted 20 lines · Stefan Roese

Without this patch, boot shows this messages upon NAND detection:

NAND: ONFI flash detected
ONFI param page 0 valid
ONFI flash detected
ONFI param page 0 valid
128 MiB

With this patch, its back to the U-Boot "standard":

NAND: 128 MiB

Tested on x600 (SPEAr600).

Quoted 3 lines

---
drivers/mtd/nand/nand_base.c | 5 +++--

 1 file changed, 3 insertions(+), 2 deletions(-)

Applied to u-boot-nand-flash.

BTW, I don't see any boards enabling the ONFI code at the moment...

-Scott

#3 lore raw
Quoted 21 lines · Scott Wood
Quoted 20 lines · Stefan Roese

Without this patch, boot shows this messages upon NAND detection:

NAND: ONFI flash detected
ONFI param page 0 valid
ONFI flash detected
ONFI param page 0 valid
128 MiB

With this patch, its back to the U-Boot "standard":

NAND: 128 MiB

Tested on x600 (SPEAr600).

Quoted 5 lines
Quoted 3 lines

---
drivers/mtd/nand/nand_base.c | 5 +++--

 1 file changed, 3 insertions(+), 2 deletions(-)

Applied to u-boot-nand-flash.

Thanks.

Quoted 1 line

BTW, I don't see any boards enabling the ONFI code at the moment...

The pending (already posted) SPEAr patches will use it.

Thanks,
Stefan