[U-Boot] [PATCH v7] nand/denali: Adding Denali NAND driver support

Masahiro Yamada yamada.m at jp.panasonic.com
Thu Apr 24 12:22:28 CEST 2014


Hi Chin,


On Wed, 23 Apr 2014 02:06:58 -0500
Chin Liang See <clsee at altera.com> wrote:

> Hi Masahiro,
> 
> 
> On Fri, 2014-04-18 at 20:41 +0900, Masahiro Yamada wrote:
> > Hi Chin,
> > 
> > 
> > I found another fatal problem in v7.
> > "nand markbad" command does not work at all.
> > I think write_oob_data() is buggy.
> 
> I believe I already comment that on the previous mail. In short, its
> working for me as I am using the BBT within the flash.

As I commented in another reply,
I guess it is working for you on v2013.01 release.
But I doubt it on the current u-boot/master.



> > 
> > 
> > How about squashing
> > http://patchwork.ozlabs.org/patch/340277/
> > http://patchwork.ozlabs.org/patch/340278/
> > to v7 and posting v8.
> > 
> 
> If you are ok with the comments, I can go ahead to create the v8 with
> below changes
> 1. Change denali.xx to denali->xx
> 2. Enhancement of nand bad bad block scanning function
> 

I found another bug.
NAND_BBT_USE_FLASH and NAND_BBT_NO_OOB must be added to
nand->bbt_options.

Please include this fix too in version 8.


  @@ -1162,13 +1162,13 @@ static int denali_nand_init(struct nand_chip *nand)
         /* check whether flash got BBT table (located at end of flash). As we
          * use NAND_BBT_NO_OOB, the BBT page will start with
          * bbt_pattern. We will have mirror pattern too */
 -       nand->options |= NAND_BBT_USE_FLASH;
 +       nand->bbt_options |= NAND_BBT_USE_FLASH;
         /*
          * We are using main + spare with ECC support. As BBT need ECC support,
          * we need to ensure BBT code don't write to OOB for the BBT pattern.
          * All BBT info will be stored into data area with ECC support.
          */
 -       nand->options |= NAND_BBT_NO_OOB;
 +       nand->bbt_options |= NAND_BBT_NO_OOB;
  #endif
  
         nand->ecc.mode = NAND_ECC_HW;


Best Regards
Masahiro Yamada



More information about the U-Boot mailing list