[U-Boot] NOR sectors are not all protected as they should be.

Alexandre Gambier a.gambier at ftemaximal.fr
Thu Feb 10 09:12:49 CET 2011


Dear Wolfgang,

Thanks for your reply and your help.

On 02/09/2011 07:50 PM, Wolfgang Denk wrote:
>
>> The first sectors #0,1,2,3 are protected and sectors #8,9 (U-Boot
>> environment) are protected.
>> It should be sectors #0,1,2,3,4,5,6,7 and sectors #8,9.
> No, it should not.  Only the sectors that actually contain the U-Boot
> code and environment are protected.  Obviously your image is small
> enough to fit in the first 4 sectors (= 256 KiB).  Actually this is a
> perfectly normal size, and your reservation of 512 KiB was just a
> waste of memory.  You can see that the following sectors are unused
> from the 'E' (= empty) flag.
Even if the first 4 sectors are empty they are protected (see below). So 
the protected sectors are not selected depending on if U-Boot is burnt 
in them, isn't it ?

  Sector Start Addresses:
   A0000000 E RO   A0010000 E RO   A0020000 E RO   A0030000 E RO   
A0040000 E
   A0050000 E      A0060000 E      A0070000 E      A0080000   RO   
A0090000 E RO
   A00A0000 E      A00B0000 E      A00C0000 E      A00D0000 E      
A00E0000 E
   A00F0000 E      A0100000 E      A0110000 E      A0120000 E      
A0130000 E
   A0140000 E      A0150000 E      A0160000 E      A0170000 E      
A0180000 E
   A0190000 E      A01A0000 E      A01B0000 E      A01C0000 E      
A01D0000 E
   A01E0000 E      A01F0000 E      A0200000 E      A0210000 E      
A0220000 E

I know my image fit in 256KiB, my image is 220KiB that I reserved more 
space just in case for the future releases.

> When they don't contain any code, there is also no need to pretect
> them, right?
It should be, but it's not completely true.

Best regards.
>
> Best regards,
>
> Wolfgang Denk
>


More information about the U-Boot mailing list