From: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
To: Arnaud Ebalard <arno@natisbad.org>
Cc: Lior Amsalem <alior@marvell.com>,
Thomas Petazzoni <thomas.petazzoni@free-electrons.com>,
Jason Cooper <jason@lakedaemon.net>,
linux-mtd@lists.infradead.org,
Gregory Clement <gregory.clement@free-electrons.com>,
Brian Norris <computersforpeace@gmail.com>,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v5 00/14] Armada 370/XP NAND supportg
Date: Thu, 5 Dec 2013 19:24:31 -0300 [thread overview]
Message-ID: <20131205222430.GB2469@localhost> (raw)
In-Reply-To: <87d2lbrpvy.fsf@natisbad.org>
On Thu, Dec 05, 2013 at 09:42:25PM +0100, Arnaud Ebalard wrote:
> Hi Ezequiel,
>
> arno@natisbad.org (Arnaud Ebalard) writes:
>
> > Could you try and dump the block to another flash. As I don't think I can
> > attach a binary blob to this email, can you drop the following in a
> > python shell:
> >
> > l = ["55 42 49 23 01 00 00 00 00 00 00 00 00 00 00 02",
> > "00 00 08 00 00 00 10 00 16 9a 76 a5 00 00 00 00",
> > "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00",
> > "00 00 00 00 00 00 00 00 00 00 00 00 65 9c 26 3a",
> > "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"*0x7b,
> > "00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00",
> > "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff",
> > "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff"*0x1f7f]
> >
> > open("/tmp/block.raw", "w").write("".join(l).replace(' ', '').decode("hex"))
> >
> > FWIW, you should have the following sha256 for the file:
> > d3e5534e054f2ab1220194c434d90fbfe9580459de887016db8e308739aa3a7b
> >
> > If you have any additional idea, I am interested. I have no more time
> > this evening to test the other debug patch you sent but I will
> > definitely give it a try tomorrow.
>
> I reused the block above to test on the kernel w/ your debug patch
> applied:
>
> root@thin:~# python
> Python 2.7.6 (default, Nov 19 2013, 18:53:23)
> [GCC 4.8.2] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> l = ["55 42 49 23 01 00 00 00 00 00 00 00 00 00 00 02",
> "00 00 08 00 00 00 10 00 16 9a 76 a5 00 00 00 00",
> "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00",
> "00 00 00 00 00 00 00 00 00 00 00 00 65 9c 26 3a",
> "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"*0x7b,
> "00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00",
> "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff",
> "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff"*0x1f7f]
>
> >>> l = ["55 42 49 23 01 00 00 00 00 00 00 00 00 00 00 02",
> ... "00 00 08 00 00 00 10 00 16 9a 76 a5 00 00 00 00",
> ... "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00",
> ... "00 00 00 00 00 00 00 00 00 00 00 00 65 9c 26 3a",
> ... "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"*0x7b,
> ... "00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00",
> ... "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff",
> ... "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff"*0x1f7f]
> >>>
> >>> open("/tmp/block.raw", "w").write("".join(l).replace(' ', '').decode("hex")) root@thin:~#
>
> root@thin:/sys/kernel/debug/dynamic_debug# flash_erase /dev/mtd4 0 1
> Erasing 128 Kibyte @ 0 -- 100 % complete
>
> root@thin:/sys/kernel/debug/dynamic_debug# nandwrite /dev/mtd4 /tmp/block.raw
> Writing data to block 0 at offset 0x0
> [ 784.543390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 0, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 00000000 to 0x01ffff
> Writing data to block 1 at offset 0x20000
> [ 784.743391] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 1, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x020000 to 0x03ffff
> Writing data to block 2 at offset 0x40000
> [ 784.943390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 2, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x040000 to 0x05ffff
> Writing data to block 3 at offset 0x60000
> [ 785.143391] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 3, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x060000 to 0x07ffff
> Writing data to block 4 at offset 0x80000
> [ 785.343388] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 4, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x080000 to 0x09ffff
> Writing data to block 5 at offset 0xa0000
> [ 785.543390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 5, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x0a0000 to 0x0bffff
> Writing data to block 6 at offset 0xc0000
> [ 785.743390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 6, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x0c0000 to 0x0dffff
> Writing data to block 7 at offset 0xe0000
>
> And here is what I get in kernel logs:
>
> [ 766.262816] Command0 0x810070
> [ 766.262827] Command1 0x0
> [ 766.262833] Command2 0x0
> [ 766.262838] Command3 0x0
> [ 766.262853] Command0 0x24bd060
> [ 766.262858] Command1 0x1800
> [ 766.262863] Command2 0x0
> [ 766.262868] Command3 0x0
> [ 766.263617] Status: ready
> [ 766.263937] Waiting for device to be ready
> [ 766.263945] Device is ready
> [ 784.345577] Command0 0x810070
> [ 784.345588] Command1 0x0
> [ 784.345594] Command2 0x0
> [ 784.345599] Command3 0x0
> [ 784.345626] Command0 0x62c1080
> [ 784.345632] Command1 0x18000000
> [ 784.345637] Command2 0x0
> [ 784.345642] Command3 0x0
> [ 784.345960] Status: ready
> [ 784.345976] Waiting for device to be ready
> [ 784.345981] Device is ready
> [ 784.346006] Command0 0x810070
> [ 784.346012] Command1 0x0
> [ 784.346017] Command2 0x0
> [ 784.346022] Command3 0x0
> [ 784.346044] Waiting for device to be ready
> [ 784.543390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> [ 784.548850] Command0 0x810070
> [ 784.548857] Command1 0x0
> [ 784.548863] Command2 0x0
> [ 784.548868] Command3 0x0
> [ 784.548888] Command0 0x24bd060
> [ 784.548893] Command1 0x1800
> [ 784.548898] Command2 0x0
> [ 784.548903] Command3 0x0
> [ 784.549648] Status: ready
> [ 784.549661] Waiting for device to be ready
> [ 784.549667] Device is ready
> [ 784.549701] Command0 0x810070
> [ 784.549707] Command1 0x0
> [ 784.549712] Command2 0x0
> [ 784.549716] Command3 0x0
> [ 784.549736] Command0 0x62c1080
> [ 784.549742] Command1 0x18400000
> [ 784.549747] Command2 0x0
> [ 784.549751] Command3 0x0
> [ 784.550074] Status: ready
> [ 784.550087] Waiting for device to be ready
> [ 784.550093] Device is ready
> [ 784.550109] Command0 0x810070
> [ 784.550115] Command1 0x0
> [ 784.550119] Command2 0x0
> [ 784.550124] Command3 0x0
> [ 784.550146] Waiting for device to be ready
> [ 784.743391] pxa3xx-nand d00d0000.nand: Ready time out!!!
> [ 784.748780] Command0 0x810070
> [ 784.748786] Command1 0x0
> [ 784.748792] Command2 0x0
> [ 784.748797] Command3 0x0
> [ 784.748815] Command0 0x24bd060
> [ 784.748821] Command1 0x1840
> [ 784.748826] Command2 0x0
> [ 784.748831] Command3 0x0
> [ 784.749575] Status: ready
> [ 784.749589] Waiting for device to be ready
> [ 784.749595] Device is ready
> [ 784.749628] Command0 0x810070
> [ 784.749634] Command1 0x0
> [ 784.749639] Command2 0x0
> [ 784.749644] Command3 0x0
> [ 784.749663] Command0 0x62c1080
> [ 784.749669] Command1 0x18800000
> [ 784.749674] Command2 0x0
> [ 784.749679] Command3 0x0
> [ 784.749995] Status: ready
> [ 784.750007] Waiting for device to be ready
> [ 784.750013] Device is ready
> [ 784.750028] Command0 0x810070
>
>
> So let's now do the same with a fully random block:
>
> root@thin:/# dd if=/dev/urandom of=/tmp/block.random bs=131072 count=1
> 1+0 records in
> 1+0 records out
> 131072 bytes (131 kB) copied, 0.0406636 s, 3.2 MB/s
>
> root@thin:~# flash_erase /dev/mtd4 0 1
> Erasing 128 Kibyte @ 0 -- 100 % complete
>
> root@thin:~# nandwrite /dev/mtd4 /tmp/block.random
> Writing data to block 0 at offset 0x0
>
> In the log, I get the following:
>
> [ 1422.296953] Command0 0x810070
> [ 1422.296965] Command1 0x0
> [ 1422.296970] Command2 0x0
> [ 1422.296975] Command3 0x0
> [ 1422.296990] Command0 0x24bd060
> [ 1422.296996] Command1 0x1800
> [ 1422.297001] Command2 0x0
> [ 1422.297006] Command3 0x0
> [ 1422.297752] Status: ready
> [ 1422.297767] Waiting for device to be ready
> [ 1422.297773] Device is ready
> [ 1488.147298] Command0 0x810070
> [ 1488.147310] Command1 0x0
> [ 1488.147316] Command2 0x0
> [ 1488.147321] Command3 0x0
> [ 1488.147340] Command0 0x62c1080
> [ 1488.147345] Command1 0x18000000
> [ 1488.147350] Command2 0x0
> [ 1488.147355] Command3 0x0
> [ 1488.147673] Status: ready
> [ 1488.147689] Waiting for device to be ready
> [ 1488.147695] Device is ready
> [ 1488.147720] Command0 0x810070
> [ 1488.147725] Command1 0x0
> [ 1488.147730] Command2 0x0
> [ 1488.147735] Command3 0x0
> [ 1488.147754] Command0 0x62c1080
> [ 1488.147759] Command1 0x18010000
> [ 1488.147764] Command2 0x0
> [ 1488.147769] Command3 0x0
> [ 1488.148085] Status: ready
> [ 1488.148098] Waiting for device to be ready
> [ 1488.148103] Device is ready
> [ 1488.148125] Command0 0x810070
> [ 1488.148130] Command1 0x0
> [ 1488.148135] Command2 0x0
> [ 1488.148140] Command3 0x0
> [ 1488.148158] Command0 0x62c1080
> [ 1488.148164] Command1 0x18020000
> [ 1488.148169] Command2 0x0
> [ 1488.148174] Command3 0x0
> [ 1488.148490] Status: ready
> [ 1488.148503] Waiting for device to be ready
> [ 1488.148508] Device is ready
> [ 1488.148537] Command0 0x810070
> [ 1488.148543] Command1 0x0
> [ 1488.148548] Command2 0x0
> [ 1488.148553] Command3 0x0
> [ 1488.148567] Command0 0x62c1080
> [ 1488.148572] Command1 0x18030000
> [ 1488.148577] Command2 0x0
> [ 1488.148582] Command3 0x0
> [ 1488.148955] Status: ready
> [ 1488.148968] Waiting for device to be ready
> [ 1488.148973] Device is ready
> [ 1488.148995] Command0 0x810070
> [ 1488.149001] Command1 0x0
> [ 1488.149006] Command2 0x0
> [ 1488.149011] Command3 0x0
> [ 1488.149029] Command0 0x62c1080
> [ 1488.149035] Command1 0x18040000
> [ 1488.149039] Command2 0x0
> [ 1488.149044] Command3 0x0
> [ 1488.149417] Status: ready
> [ 1488.149429] Waiting for device to be ready
> [ 1488.149434] Device is ready
> [ 1488.149456] Command0 0x810070
> [ 1488.149462] Command1 0x0
> [ 1488.149466] Command2 0x0
> [ 1488.149471] Command3 0x0
> [ 1488.149486] Command0 0x62c1080
> [ 1488.149491] Command1 0x18050000
> [ 1488.149496] Command2 0x0
> [ 1488.149501] Command3 0x0
> [ 1488.149817] Status: ready
> [ 1488.149830] Waiting for device to be ready
> [ 1488.149835] Device is ready
> [ 1488.149857] Command0 0x810070
> [ 1488.149863] Command1 0x0
> [ 1488.149867] Command2 0x0
> [ 1488.149872] Command3 0x0
> [ 1488.149891] Command0 0x62c1080
> [ 1488.149896] Command1 0x18060000
> [ 1488.149901] Command2 0x0
> [ 1488.149906] Command3 0x0
> [ 1488.150279] Status: ready
> [ 1488.150292] Waiting for device to be ready
> [ 1488.150297] Device is ready
> [ 1488.150319] Command0 0x810070
> [ 1488.150325] Command1 0x0
> [ 1488.150330] Command2 0x0
> [ 1488.150334] Command3 0x0
> [ 1488.150353] Command0 0x62c1080
> [ 1488.150359] Command1 0x18070000
> [ 1488.150363] Command2 0x0
> [ 1488.150368] Command3 0x0
> [ 1488.150685] Status: ready
> [ 1488.150697] Waiting for device to be ready
> [ 1488.150702] Device is ready
>
> If you had the time to test the offending block on another device, did
> you manage to reproduce what I get?
>
Thanks for the command trace! I'll look at this in detail tomorrow
and let you know.
--
Ezequiel García, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com
WARNING: multiple messages have this Message-ID (diff)
From: ezequiel.garcia@free-electrons.com (Ezequiel Garcia)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v5 00/14] Armada 370/XP NAND supportg
Date: Thu, 5 Dec 2013 19:24:31 -0300 [thread overview]
Message-ID: <20131205222430.GB2469@localhost> (raw)
In-Reply-To: <87d2lbrpvy.fsf@natisbad.org>
On Thu, Dec 05, 2013 at 09:42:25PM +0100, Arnaud Ebalard wrote:
> Hi Ezequiel,
>
> arno at natisbad.org (Arnaud Ebalard) writes:
>
> > Could you try and dump the block to another flash. As I don't think I can
> > attach a binary blob to this email, can you drop the following in a
> > python shell:
> >
> > l = ["55 42 49 23 01 00 00 00 00 00 00 00 00 00 00 02",
> > "00 00 08 00 00 00 10 00 16 9a 76 a5 00 00 00 00",
> > "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00",
> > "00 00 00 00 00 00 00 00 00 00 00 00 65 9c 26 3a",
> > "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"*0x7b,
> > "00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00",
> > "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff",
> > "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff"*0x1f7f]
> >
> > open("/tmp/block.raw", "w").write("".join(l).replace(' ', '').decode("hex"))
> >
> > FWIW, you should have the following sha256 for the file:
> > d3e5534e054f2ab1220194c434d90fbfe9580459de887016db8e308739aa3a7b
> >
> > If you have any additional idea, I am interested. I have no more time
> > this evening to test the other debug patch you sent but I will
> > definitely give it a try tomorrow.
>
> I reused the block above to test on the kernel w/ your debug patch
> applied:
>
> root at thin:~# python
> Python 2.7.6 (default, Nov 19 2013, 18:53:23)
> [GCC 4.8.2] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> l = ["55 42 49 23 01 00 00 00 00 00 00 00 00 00 00 02",
> "00 00 08 00 00 00 10 00 16 9a 76 a5 00 00 00 00",
> "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00",
> "00 00 00 00 00 00 00 00 00 00 00 00 65 9c 26 3a",
> "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"*0x7b,
> "00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00",
> "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff",
> "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff"*0x1f7f]
>
> >>> l = ["55 42 49 23 01 00 00 00 00 00 00 00 00 00 00 02",
> ... "00 00 08 00 00 00 10 00 16 9a 76 a5 00 00 00 00",
> ... "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00",
> ... "00 00 00 00 00 00 00 00 00 00 00 00 65 9c 26 3a",
> ... "00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00"*0x7b,
> ... "00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00",
> ... "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff",
> ... "ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff"*0x1f7f]
> >>>
> >>> open("/tmp/block.raw", "w").write("".join(l).replace(' ', '').decode("hex")) root at thin:~#
>
> root at thin:/sys/kernel/debug/dynamic_debug# flash_erase /dev/mtd4 0 1
> Erasing 128 Kibyte @ 0 -- 100 % complete
>
> root at thin:/sys/kernel/debug/dynamic_debug# nandwrite /dev/mtd4 /tmp/block.raw
> Writing data to block 0 at offset 0x0
> [ 784.543390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 0, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 00000000 to 0x01ffff
> Writing data to block 1 at offset 0x20000
> [ 784.743391] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 1, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x020000 to 0x03ffff
> Writing data to block 2 at offset 0x40000
> [ 784.943390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 2, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x040000 to 0x05ffff
> Writing data to block 3 at offset 0x60000
> [ 785.143391] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 3, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x060000 to 0x07ffff
> Writing data to block 4 at offset 0x80000
> [ 785.343388] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 4, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x080000 to 0x09ffff
> Writing data to block 5 at offset 0xa0000
> [ 785.543390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 5, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x0a0000 to 0x0bffff
> Writing data to block 6 at offset 0xc0000
> [ 785.743390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> libmtd: error!: cannot write 2048 bytes to mtd4 (eraseblock 6, offset 2048)
> error 5 (Input/output error)
> Erasing failed write from 0x0c0000 to 0x0dffff
> Writing data to block 7 at offset 0xe0000
>
> And here is what I get in kernel logs:
>
> [ 766.262816] Command0 0x810070
> [ 766.262827] Command1 0x0
> [ 766.262833] Command2 0x0
> [ 766.262838] Command3 0x0
> [ 766.262853] Command0 0x24bd060
> [ 766.262858] Command1 0x1800
> [ 766.262863] Command2 0x0
> [ 766.262868] Command3 0x0
> [ 766.263617] Status: ready
> [ 766.263937] Waiting for device to be ready
> [ 766.263945] Device is ready
> [ 784.345577] Command0 0x810070
> [ 784.345588] Command1 0x0
> [ 784.345594] Command2 0x0
> [ 784.345599] Command3 0x0
> [ 784.345626] Command0 0x62c1080
> [ 784.345632] Command1 0x18000000
> [ 784.345637] Command2 0x0
> [ 784.345642] Command3 0x0
> [ 784.345960] Status: ready
> [ 784.345976] Waiting for device to be ready
> [ 784.345981] Device is ready
> [ 784.346006] Command0 0x810070
> [ 784.346012] Command1 0x0
> [ 784.346017] Command2 0x0
> [ 784.346022] Command3 0x0
> [ 784.346044] Waiting for device to be ready
> [ 784.543390] pxa3xx-nand d00d0000.nand: Ready time out!!!
> [ 784.548850] Command0 0x810070
> [ 784.548857] Command1 0x0
> [ 784.548863] Command2 0x0
> [ 784.548868] Command3 0x0
> [ 784.548888] Command0 0x24bd060
> [ 784.548893] Command1 0x1800
> [ 784.548898] Command2 0x0
> [ 784.548903] Command3 0x0
> [ 784.549648] Status: ready
> [ 784.549661] Waiting for device to be ready
> [ 784.549667] Device is ready
> [ 784.549701] Command0 0x810070
> [ 784.549707] Command1 0x0
> [ 784.549712] Command2 0x0
> [ 784.549716] Command3 0x0
> [ 784.549736] Command0 0x62c1080
> [ 784.549742] Command1 0x18400000
> [ 784.549747] Command2 0x0
> [ 784.549751] Command3 0x0
> [ 784.550074] Status: ready
> [ 784.550087] Waiting for device to be ready
> [ 784.550093] Device is ready
> [ 784.550109] Command0 0x810070
> [ 784.550115] Command1 0x0
> [ 784.550119] Command2 0x0
> [ 784.550124] Command3 0x0
> [ 784.550146] Waiting for device to be ready
> [ 784.743391] pxa3xx-nand d00d0000.nand: Ready time out!!!
> [ 784.748780] Command0 0x810070
> [ 784.748786] Command1 0x0
> [ 784.748792] Command2 0x0
> [ 784.748797] Command3 0x0
> [ 784.748815] Command0 0x24bd060
> [ 784.748821] Command1 0x1840
> [ 784.748826] Command2 0x0
> [ 784.748831] Command3 0x0
> [ 784.749575] Status: ready
> [ 784.749589] Waiting for device to be ready
> [ 784.749595] Device is ready
> [ 784.749628] Command0 0x810070
> [ 784.749634] Command1 0x0
> [ 784.749639] Command2 0x0
> [ 784.749644] Command3 0x0
> [ 784.749663] Command0 0x62c1080
> [ 784.749669] Command1 0x18800000
> [ 784.749674] Command2 0x0
> [ 784.749679] Command3 0x0
> [ 784.749995] Status: ready
> [ 784.750007] Waiting for device to be ready
> [ 784.750013] Device is ready
> [ 784.750028] Command0 0x810070
>
>
> So let's now do the same with a fully random block:
>
> root at thin:/# dd if=/dev/urandom of=/tmp/block.random bs=131072 count=1
> 1+0 records in
> 1+0 records out
> 131072 bytes (131 kB) copied, 0.0406636 s, 3.2 MB/s
>
> root at thin:~# flash_erase /dev/mtd4 0 1
> Erasing 128 Kibyte @ 0 -- 100 % complete
>
> root at thin:~# nandwrite /dev/mtd4 /tmp/block.random
> Writing data to block 0 at offset 0x0
>
> In the log, I get the following:
>
> [ 1422.296953] Command0 0x810070
> [ 1422.296965] Command1 0x0
> [ 1422.296970] Command2 0x0
> [ 1422.296975] Command3 0x0
> [ 1422.296990] Command0 0x24bd060
> [ 1422.296996] Command1 0x1800
> [ 1422.297001] Command2 0x0
> [ 1422.297006] Command3 0x0
> [ 1422.297752] Status: ready
> [ 1422.297767] Waiting for device to be ready
> [ 1422.297773] Device is ready
> [ 1488.147298] Command0 0x810070
> [ 1488.147310] Command1 0x0
> [ 1488.147316] Command2 0x0
> [ 1488.147321] Command3 0x0
> [ 1488.147340] Command0 0x62c1080
> [ 1488.147345] Command1 0x18000000
> [ 1488.147350] Command2 0x0
> [ 1488.147355] Command3 0x0
> [ 1488.147673] Status: ready
> [ 1488.147689] Waiting for device to be ready
> [ 1488.147695] Device is ready
> [ 1488.147720] Command0 0x810070
> [ 1488.147725] Command1 0x0
> [ 1488.147730] Command2 0x0
> [ 1488.147735] Command3 0x0
> [ 1488.147754] Command0 0x62c1080
> [ 1488.147759] Command1 0x18010000
> [ 1488.147764] Command2 0x0
> [ 1488.147769] Command3 0x0
> [ 1488.148085] Status: ready
> [ 1488.148098] Waiting for device to be ready
> [ 1488.148103] Device is ready
> [ 1488.148125] Command0 0x810070
> [ 1488.148130] Command1 0x0
> [ 1488.148135] Command2 0x0
> [ 1488.148140] Command3 0x0
> [ 1488.148158] Command0 0x62c1080
> [ 1488.148164] Command1 0x18020000
> [ 1488.148169] Command2 0x0
> [ 1488.148174] Command3 0x0
> [ 1488.148490] Status: ready
> [ 1488.148503] Waiting for device to be ready
> [ 1488.148508] Device is ready
> [ 1488.148537] Command0 0x810070
> [ 1488.148543] Command1 0x0
> [ 1488.148548] Command2 0x0
> [ 1488.148553] Command3 0x0
> [ 1488.148567] Command0 0x62c1080
> [ 1488.148572] Command1 0x18030000
> [ 1488.148577] Command2 0x0
> [ 1488.148582] Command3 0x0
> [ 1488.148955] Status: ready
> [ 1488.148968] Waiting for device to be ready
> [ 1488.148973] Device is ready
> [ 1488.148995] Command0 0x810070
> [ 1488.149001] Command1 0x0
> [ 1488.149006] Command2 0x0
> [ 1488.149011] Command3 0x0
> [ 1488.149029] Command0 0x62c1080
> [ 1488.149035] Command1 0x18040000
> [ 1488.149039] Command2 0x0
> [ 1488.149044] Command3 0x0
> [ 1488.149417] Status: ready
> [ 1488.149429] Waiting for device to be ready
> [ 1488.149434] Device is ready
> [ 1488.149456] Command0 0x810070
> [ 1488.149462] Command1 0x0
> [ 1488.149466] Command2 0x0
> [ 1488.149471] Command3 0x0
> [ 1488.149486] Command0 0x62c1080
> [ 1488.149491] Command1 0x18050000
> [ 1488.149496] Command2 0x0
> [ 1488.149501] Command3 0x0
> [ 1488.149817] Status: ready
> [ 1488.149830] Waiting for device to be ready
> [ 1488.149835] Device is ready
> [ 1488.149857] Command0 0x810070
> [ 1488.149863] Command1 0x0
> [ 1488.149867] Command2 0x0
> [ 1488.149872] Command3 0x0
> [ 1488.149891] Command0 0x62c1080
> [ 1488.149896] Command1 0x18060000
> [ 1488.149901] Command2 0x0
> [ 1488.149906] Command3 0x0
> [ 1488.150279] Status: ready
> [ 1488.150292] Waiting for device to be ready
> [ 1488.150297] Device is ready
> [ 1488.150319] Command0 0x810070
> [ 1488.150325] Command1 0x0
> [ 1488.150330] Command2 0x0
> [ 1488.150334] Command3 0x0
> [ 1488.150353] Command0 0x62c1080
> [ 1488.150359] Command1 0x18070000
> [ 1488.150363] Command2 0x0
> [ 1488.150368] Command3 0x0
> [ 1488.150685] Status: ready
> [ 1488.150697] Waiting for device to be ready
> [ 1488.150702] Device is ready
>
> If you had the time to test the offending block on another device, did
> you manage to reproduce what I get?
>
Thanks for the command trace! I'll look at this in detail tomorrow
and let you know.
--
Ezequiel Garc?a, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com
next prev parent reply other threads:[~2013-12-05 22:24 UTC|newest]
Thread overview: 122+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-14 21:25 [PATCH v5 00/14] Armada 370/XP NAND support Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 01/14] mtd: nand: pxa3xx: Use a completion to signal device ready Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 02/14] mtd: nand: pxa3xx: Use waitfunc() to wait for the device to be ready Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 03/14] mtd: nand: pxa3xx: Add bad block handling Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 22:12 ` Brian Norris
2013-11-14 22:12 ` Brian Norris
2013-11-14 22:37 ` Ezequiel Garcia
2013-11-14 22:37 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 04/14] mtd: nand: pxa3xx: Add driver-specific ECC BCH support Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 05/14] mtd: nand: pxa3xx: Clear cmd buffer #3 (NDCB3) on command start Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 22:18 ` Brian Norris
2013-11-14 22:18 ` Brian Norris
2013-11-14 21:25 ` [PATCH v5 06/14] mtd: nand: pxa3xx: Add helper function to set page address Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 07/14] mtd: nand: pxa3xx: Remove READ0 switch/case falltrough Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 08/14] mtd: nand: pxa3xx: Split prepare_command_pool() in two stages Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 09/14] mtd: nand: pxa3xx: Move the data buffer clean to prepare_start_command() Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 22:25 ` Brian Norris
2013-11-14 22:25 ` Brian Norris
2013-11-14 22:45 ` Ezequiel Garcia
2013-11-14 22:45 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 10/14] mtd: nand: pxa3xx: Fix SEQIN column address set Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 11/14] mtd: nand: pxa3xx: Add a read/write buffers markers Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 12/14] mtd: nand: pxa3xx: Introduce multiple page I/O support Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 22:40 ` Brian Norris
2013-11-14 22:40 ` Brian Norris
2013-11-14 23:02 ` Ezequiel Garcia
2013-11-14 23:02 ` Ezequiel Garcia
2013-11-14 23:07 ` Brian Norris
2013-11-14 23:07 ` Brian Norris
2013-11-14 21:25 ` [PATCH v5 13/14] mtd: nand: pxa3xx: Add multiple chunk write support Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 21:25 ` [PATCH v5 14/14] mtd: nand: pxa3xx: Add ECC BCH correctable errors detection Ezequiel Garcia
2013-11-14 21:25 ` Ezequiel Garcia
2013-11-14 23:04 ` [PATCH v5 00/14] Armada 370/XP NAND support Brian Norris
2013-11-14 23:04 ` Brian Norris
2013-11-14 23:05 ` Brian Norris
2013-11-14 23:05 ` Brian Norris
2013-11-14 23:15 ` Ezequiel Garcia
2013-11-14 23:15 ` Ezequiel Garcia
2013-11-14 23:17 ` Brian Norris
2013-11-14 23:17 ` Brian Norris
2013-11-15 7:59 ` Daniel Mack
2013-11-15 7:59 ` Daniel Mack
2013-11-15 13:07 ` Ezequiel Garcia
2013-11-15 13:07 ` Ezequiel Garcia
2013-11-15 13:47 ` Daniel Mack
2013-11-15 13:47 ` Daniel Mack
2013-11-15 14:27 ` Ezequiel Garcia
2013-11-15 14:27 ` Ezequiel Garcia
2013-11-15 14:30 ` Daniel Mack
2013-11-15 14:30 ` Daniel Mack
2013-11-15 18:05 ` Brian Norris
2013-11-15 18:05 ` Brian Norris
2013-11-15 18:35 ` Ezequiel Garcia
2013-11-15 18:35 ` Ezequiel Garcia
2013-11-24 14:08 ` Arnaud Ebalard
2013-11-24 14:08 ` Arnaud Ebalard
2013-11-24 14:22 ` Thomas Petazzoni
2013-11-24 14:22 ` Thomas Petazzoni
2013-11-25 12:03 ` Ezequiel Garcia
2013-11-25 12:03 ` Ezequiel Garcia
2013-11-25 23:04 ` Arnaud Ebalard
2013-11-25 23:04 ` Arnaud Ebalard
2013-11-26 12:40 ` Ezequiel Garcia
2013-11-26 12:40 ` Ezequiel Garcia
2013-11-27 20:24 ` Arnaud Ebalard
2013-11-27 20:24 ` Arnaud Ebalard
2013-11-27 20:52 ` Arnaud Ebalard
2013-11-27 20:52 ` Arnaud Ebalard
2013-11-28 7:48 ` Ricard Wanderlof
2013-11-28 7:48 ` Ricard Wanderlof
2013-11-28 18:50 ` Ezequiel Garcia
2013-11-28 18:50 ` Ezequiel Garcia
2013-11-29 23:25 ` Arnaud Ebalard
2013-11-29 23:25 ` Arnaud Ebalard
2013-12-02 10:33 ` Ezequiel Garcia
2013-12-02 10:33 ` Ezequiel Garcia
2013-12-02 21:05 ` Arnaud Ebalard
2013-12-02 21:05 ` Arnaud Ebalard
2013-12-03 0:22 ` Ezequiel Garcia
2013-12-03 0:22 ` Ezequiel Garcia
2013-12-03 20:21 ` Arnaud Ebalard
2013-12-03 20:21 ` Arnaud Ebalard
2013-12-03 21:25 ` Arnaud Ebalard
2013-12-03 21:25 ` Arnaud Ebalard
2013-12-04 14:20 ` Ezequiel Garcia
2013-12-04 14:20 ` Ezequiel Garcia
2013-12-04 14:41 ` Ezequiel Garcia
2013-12-04 14:41 ` Ezequiel Garcia
2013-12-04 20:48 ` Arnaud Ebalard
2013-12-04 20:48 ` Arnaud Ebalard
2013-12-05 20:42 ` Arnaud Ebalard
2013-12-05 20:42 ` Arnaud Ebalard
2013-12-05 22:24 ` Ezequiel Garcia [this message]
2013-12-05 22:24 ` [PATCH v5 00/14] Armada 370/XP NAND supportg Ezequiel Garcia
2013-12-06 12:56 ` [PATCH v5 00/14] Armada 370/XP NAND support Ezequiel Garcia
2013-12-06 12:56 ` Ezequiel Garcia
2013-12-06 21:41 ` Arnaud Ebalard
2013-12-06 21:41 ` Arnaud Ebalard
2013-12-06 22:05 ` Ezequiel Garcia
2013-12-06 22:05 ` Ezequiel Garcia
2013-12-05 21:32 ` Brian Norris
2013-12-05 21:32 ` Brian Norris
2013-12-05 21:23 ` Brian Norris
2013-12-05 21:23 ` Brian Norris
2013-12-05 22:23 ` Ezequiel Garcia
2013-12-05 22:23 ` Ezequiel Garcia
2013-12-05 22:45 ` Brian Norris
2013-12-05 22:45 ` Brian Norris
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131205222430.GB2469@localhost \
--to=ezequiel.garcia@free-electrons.com \
--cc=alior@marvell.com \
--cc=arno@natisbad.org \
--cc=computersforpeace@gmail.com \
--cc=gregory.clement@free-electrons.com \
--cc=jason@lakedaemon.net \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-mtd@lists.infradead.org \
--cc=thomas.petazzoni@free-electrons.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.