[U-Boot] curious snippet in drivers/mtd/dataflash.c
    Robert P. J. Day 
    rpjday at crashcourse.ca
       
    Wed Dec 28 16:15:21 CET 2016
    
    
  
  not sure about this bit of code in that source file:
    /* Set the environment according to the label...*/
    if(protected == FLAG_PROTECT_INVALID) {
        dataflash_info[i].Device.area_list[j].protected =
            FLAG_PROTECT_INVALID;
    } else {
        dataflash_info[i].Device.area_list[j].protected =
            protected;
    }
is that not just setting the value to "protected" in both cases? what
is the point of that conditional?
rday
-- 
========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca
Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================
    
    
More information about the U-Boot
mailing list