Re: [PATCH 3/3] drivers: mtd: nand: omap: Return stat value

2018-02-23 Thread Daniel Schultz


On 02/16/2018 08:56 AM, Sascha Hauer wrote:

On Thu, Feb 15, 2018 at 01:51:26PM +0100, Daniel Schultz wrote:

Hi Sascha,


On 01/30/2018 08:11 AM, Sascha Hauer wrote:

On Mon, Jan 29, 2018 at 02:04:11PM +0100, Daniel Schultz wrote:

The read page function should return the total count of flipped bits,
otherwise the caller always thinks no bitflip occured.

Signed-off-by: Daniel Schultz 
---
   drivers/mtd/nand/nand_omap_gpmc.c | 2 +-
   1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/nand/nand_omap_gpmc.c 
b/drivers/mtd/nand/nand_omap_gpmc.c
index e18ce63..38f4960 100644
--- a/drivers/mtd/nand/nand_omap_gpmc.c
+++ b/drivers/mtd/nand/nand_omap_gpmc.c
@@ -712,7 +712,7 @@ static int omap_gpmc_read_page_bch_rom_mode(struct mtd_info 
*mtd,
else
mtd->ecc_stats.corrected += stat;
-   return 0;
+   return stat;
   }

I'm afraid this is not enough. read_page should return the maximum
number of bitflips in any ECC step. You first have to change
omap_correct_bch() so that it returns this number.

ahh, we worked on this problem a half year ago and it seems like three
patches are missing upstream:

http://lists.infradead.org/pipermail/barebox/2017-June/030385.html
http://lists.infradead.org/pipermail/barebox/2017-June/030384.html
http://lists.infradead.org/pipermail/barebox/2017-June/030355.html

Oh, I see. It seems I have either forgotten to merge them or I have
waited for feedback. Could you create a series for all missing patches
including your new patch and resend it, provided it works as expected of
course?

Yes, I will do this as soon as I have time for it.


--
Mit freundlichen Grüßen,
With best regards,
  Daniel Schultz



___
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


Re: [PATCH 3/3] drivers: mtd: nand: omap: Return stat value

2018-02-16 Thread Sascha Hauer
On Thu, Feb 15, 2018 at 01:51:26PM +0100, Daniel Schultz wrote:
> Hi Sascha,
> 
> 
> On 01/30/2018 08:11 AM, Sascha Hauer wrote:
> > On Mon, Jan 29, 2018 at 02:04:11PM +0100, Daniel Schultz wrote:
> > > The read page function should return the total count of flipped bits,
> > > otherwise the caller always thinks no bitflip occured.
> > > 
> > > Signed-off-by: Daniel Schultz 
> > > ---
> > >   drivers/mtd/nand/nand_omap_gpmc.c | 2 +-
> > >   1 file changed, 1 insertion(+), 1 deletion(-)
> > > 
> > > diff --git a/drivers/mtd/nand/nand_omap_gpmc.c 
> > > b/drivers/mtd/nand/nand_omap_gpmc.c
> > > index e18ce63..38f4960 100644
> > > --- a/drivers/mtd/nand/nand_omap_gpmc.c
> > > +++ b/drivers/mtd/nand/nand_omap_gpmc.c
> > > @@ -712,7 +712,7 @@ static int omap_gpmc_read_page_bch_rom_mode(struct 
> > > mtd_info *mtd,
> > >   else
> > >   mtd->ecc_stats.corrected += stat;
> > > - return 0;
> > > + return stat;
> > >   }
> > I'm afraid this is not enough. read_page should return the maximum
> > number of bitflips in any ECC step. You first have to change
> > omap_correct_bch() so that it returns this number.
> ahh, we worked on this problem a half year ago and it seems like three
> patches are missing upstream:
> 
> http://lists.infradead.org/pipermail/barebox/2017-June/030385.html
> http://lists.infradead.org/pipermail/barebox/2017-June/030384.html
> http://lists.infradead.org/pipermail/barebox/2017-June/030355.html

Oh, I see. It seems I have either forgotten to merge them or I have
waited for feedback. Could you create a series for all missing patches
including your new patch and resend it, provided it works as expected of
course?

Sascha

-- 
Pengutronix e.K.   | |
Industrial Linux Solutions | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0|
Amtsgericht Hildesheim, HRA 2686   | Fax:   +49-5121-206917- |

___
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


Re: [PATCH 3/3] drivers: mtd: nand: omap: Return stat value

2018-02-15 Thread Daniel Schultz

Hi Sascha,


On 01/30/2018 08:11 AM, Sascha Hauer wrote:

On Mon, Jan 29, 2018 at 02:04:11PM +0100, Daniel Schultz wrote:

The read page function should return the total count of flipped bits,
otherwise the caller always thinks no bitflip occured.

Signed-off-by: Daniel Schultz 
---
  drivers/mtd/nand/nand_omap_gpmc.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/nand/nand_omap_gpmc.c 
b/drivers/mtd/nand/nand_omap_gpmc.c
index e18ce63..38f4960 100644
--- a/drivers/mtd/nand/nand_omap_gpmc.c
+++ b/drivers/mtd/nand/nand_omap_gpmc.c
@@ -712,7 +712,7 @@ static int omap_gpmc_read_page_bch_rom_mode(struct mtd_info 
*mtd,
else
mtd->ecc_stats.corrected += stat;
  
-	return 0;

+   return stat;
  }

I'm afraid this is not enough. read_page should return the maximum
number of bitflips in any ECC step. You first have to change
omap_correct_bch() so that it returns this number.
ahh, we worked on this problem a half year ago and it seems like three 
patches are missing upstream:


http://lists.infradead.org/pipermail/barebox/2017-June/030385.html
http://lists.infradead.org/pipermail/barebox/2017-June/030384.html
http://lists.infradead.org/pipermail/barebox/2017-June/030355.html

Daniel


Sascha




--
Mit freundlichen Grüßen,
With best regards,
  Daniel Schultz

- Entwicklung -
Tel.:   +49 6131 92 21 457
d.schu...@phytec.de
www.phytec.de

Sie finden uns auch auf: Facebook, LinkedIn, Xing, YouTube

PHYTEC Messtechnik GmbH | Robert-Koch-Str. 39 | 55129 Mainz, Germany
Geschäftsführer: Dipl.-Ing. Michael Mitezki, Dipl.-Ing. Bodo Huber |
Handelsregister Mainz HRB 4656 | Finanzamt Mainz-Mitte | St.Nr. 266500608,
DE 149059855
This E-Mail may contain confidential or privileged information. If you are
not the intended recipient (or have received this E-Mail in error) please
notify the sender immediately and destroy this E-Mail. Any unauthorized
copying, disclosure or distribution of the material in this E-Mail is
strictly forbidden.


___
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


Re: [PATCH 3/3] drivers: mtd: nand: omap: Return stat value

2018-01-29 Thread Sascha Hauer
On Mon, Jan 29, 2018 at 02:04:11PM +0100, Daniel Schultz wrote:
> The read page function should return the total count of flipped bits,
> otherwise the caller always thinks no bitflip occured.
> 
> Signed-off-by: Daniel Schultz 
> ---
>  drivers/mtd/nand/nand_omap_gpmc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/mtd/nand/nand_omap_gpmc.c 
> b/drivers/mtd/nand/nand_omap_gpmc.c
> index e18ce63..38f4960 100644
> --- a/drivers/mtd/nand/nand_omap_gpmc.c
> +++ b/drivers/mtd/nand/nand_omap_gpmc.c
> @@ -712,7 +712,7 @@ static int omap_gpmc_read_page_bch_rom_mode(struct 
> mtd_info *mtd,
>   else
>   mtd->ecc_stats.corrected += stat;
>  
> - return 0;
> + return stat;
>  }

I'm afraid this is not enough. read_page should return the maximum
number of bitflips in any ECC step. You first have to change
omap_correct_bch() so that it returns this number.

Sascha


-- 
Pengutronix e.K.   | |
Industrial Linux Solutions | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0|
Amtsgericht Hildesheim, HRA 2686   | Fax:   +49-5121-206917- |

___
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox