[U-Boot] NAND 16 bit buswidth issue

Pete Murray pmurray at dawning.com
Thu Aug 19 22:22:40 CEST 2010


    The controller driver being used is ndfc.c, it doesn't set the 
options though.  From what I can tell, nand.c calls nand_scan without 
actually setting the nand options.  I have been setting chip->options to 
include NAND_BUSWIDTH_16, but want to move all my changes back to board 
specific code to eventually submit for review.  



 /* Lookup the flash id */
        for (i = 0; nand_flash_ids[i].name != NULL; i++) {
                if (dev_id == nand_flash_ids[i].id) {
                        type =  &nand_flash_ids[i];
                        break;
                }
        }

        if (!type)
                return ERR_PTR(-ENODEV);

        if (!mtd->name)
                mtd->name = type->name;

        chip->chipsize = type->chipsize << 20;
        
   
 Since type is set to the options read from nand_flash_ids in the 
nand_get_flash_type function, would it be appropriate to just set 
chip->options to type->options as is done with the chipsize?  If not, 
what would be the most acceptable way to do this?


       



More information about the U-Boot mailing list