Re: [Bug] mtd: rawnand: gpmi

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Hi Sascha

Please let me know when you have some time to look into this :-)
I dosen't seem right that it writes the bbt on a 4.19 series kernel twice


For me the disturbing part is:

[    4.175918] Bad block table not found for chip 0
[    4.184059] Bad block table not found for chip 0

Writing the BBT twice is expected.

Thanks,
Miquèl


Hi,

Tried this:

diff --git a/drivers/mtd/nand/raw/nand_bbt.c b/drivers/mtd/nand/raw/nand_bbt.c
index 39db352f8757..b0337f8a0da4 100644
--- a/drivers/mtd/nand/raw/nand_bbt.c
+++ b/drivers/mtd/nand/raw/nand_bbt.c
@@ -1200,6 +1200,8 @@ static int nand_scan_bbt(struct mtd_info *mtd, struct nand_bbt_descr *bd)
        if (res)
                goto err;

+       search_read_bbts(mtd, buf, td, md);
+
        /* Prevent the bbt regions from erasing / writing */
        mark_bbt_region(mtd, td);
        if (md

Result is:

[ 2.191412] nand: device found, Manufacturer ID: 0x98, Chip ID: 0xdc

[ 2.198095] nand: Toshiba NAND 512MiB 3,3V 8-bit [ 2.202848] nand: 512 MiB, SLC, erase size: 256 KiB, page size: 4096, OOB size: 128 [ 2.217337] Bad block table not found for chip 0

[ 2.225535] Bad block table not found for chip 0

[ 2.230475] Scanning device for bad blocks

[    2.749832] Bad eraseblock 798 at 0x00000c780000
[    3.230712] Bad eraseblock 1536 at 0x000018000000
[    3.236263] Bad eraseblock 1537 at 0x000018040000
[    3.574122] Bad block table written to 0x00001ffc0000, version 0x01
[    3.584874] Bad block table written to 0x00001ff80000, version 0x01
[ 3.592306] Bad block table found at page 131008, version 0x01

[    3.600059] Bad block table found at page 130944, version 0x01
[ 3.607129] 3 fixed-partitions partitions found on MTD device gpmi-nand
[    3.614105] Creating 3 MTD partitions on "gpmi-nand":
[    3.619540] 0x000000000000-0x000000800000 : "boot"
[    3.635437] 0x000000800000-0x00001ca00000 : "ubi"
[ 4.018183] 0x00001ca00000-0x000020000000 : "testing"

[    4.070734] gpmi-nand 1806000.gpmi-nand: driver registered.

Seems like it's U-boot that is corrupting the table.

But I don't think it's related to the original issue with commit
ef347c0cfd619a9251e5a2f9ff72e33650a9bccb

/Sean

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/




[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux