Re: [LINUX PATCH v12 3/3] mtd: rawnand: arasan: Add support for Arasan NAND Flash Controller
From: Boris Brezillon
Date: Tue Nov 20 2018 - 06:02:59 EST
On Tue, 20 Nov 2018 07:02:08 +0000
Naga Sureshkumar Relli <nagasure@xxxxxxxxxx> wrote:
> >
> > Can you please run nandbiterrs (availaible in mtd-utils). I fear your
> > device won't pass the test.
> Yes, nandbiterror test is passing till 24bit, after that it is failing.
Can you paste the output of nandbiterrs please?
> >
> > > But we are hitting this because of erased page reading(needed in case of ubifs).
> > >
> > > >
> > > > Don't you have a bit (or several bits) reporting when the ECC engine was not able to
> > correct
> > > > data? I you do, you should base the "detect bitflips in erase pages" logic on this information.
> > > Bit reporting for several bit errors is there only for Hamming(1bit correction and 2bit
> > detection) but not in BCH.
> > >
> >
> > Then I tend to agree with Miquel: your ECC engine is broken, and I'm
> > not even sure how to deal with that yet.
> So as per the Miquel's suggestion, can I proceed to add the below one?
> "you should re-read the page in raw mode and check for the number of bitflips manually (thanks to the helpers in the core). Again, if the number of BF is above 16, we can assume the page is bad and increment ->ecc.failed accordingly."
But that's just partially fixing the problem. And you didn't answer my
previous question: what happens when you configure the ECC engine in,
say 12bit/1024 and you end up with uncorrectable errors (more than 12
bitflips in a 1k block). What's the number reported ECC_ERR_CNT? Is it
set to 13?