Merge branch 'master' of git://git.denx.de/u-boot-spi
[platform/kernel/u-boot.git] / tools / binman / README
index 10dfe57..04ed2b7 100644 (file)
@@ -330,9 +330,13 @@ image-pos:
        for each entry. This makes it easy to find out exactly where the entry
        ended up in the image, regardless of parent sections, etc.
 
+expand-size:
+       Expand the size of this entry to fit available space. This space is only
+       limited by the size of the image/section and the position of the next
+       entry.
 
-The attributes supported for images are described below. Several are similar
-to those for entries.
+The attributes supported for images and sections are described below. Several
+are similar to those for entries.
 
 size:
        Sets the image size in bytes, for example 'size = <0x100000>' for a
@@ -397,6 +401,15 @@ end-at-4gb:
        8MB ROM, the offset of the first entry would be 0xfff80000 with
        this option, instead of 0 without this option.
 
+skip-at-start:
+       This property specifies the entry offset of the first entry.
+
+       For PowerPC mpc85xx based CPU, CONFIG_SYS_TEXT_BASE is the entry
+       offset of the first entry. It can be 0xeff40000 or 0xfff40000 for
+       nor flash boot, 0x201000 for sd boot etc.
+
+       'end-at-4gb' property is not applicable where CONFIG_SYS_TEXT_BASE +
+       Image size != 4gb.
 
 Examples of the above options can be found in the tests. See the
 tools/binman/test directory.
@@ -462,6 +475,28 @@ see README.entries. This is generated from the source code using:
        binman -E >tools/binman/README.entries
 
 
+Hashing Entries
+---------------
+
+It is possible to ask binman to hash the contents of an entry and write that
+value back to the device-tree node. For example:
+
+       binman {
+               u-boot {
+                       hash {
+                               algo = "sha256";
+                       };
+               };
+       };
+
+Here, a new 'value' property will be written to the 'hash' node containing
+the hash of the 'u-boot' entry. Only SHA256 is supported at present. Whole
+sections can be hased if desired, by adding the 'hash' node to the section.
+
+The has value can be chcked at runtime by hashing the data actually read and
+comparing this has to the value in the device tree.
+
+
 Order of image creation
 -----------------------
 
@@ -593,6 +628,22 @@ the device tree. These can be used by U-Boot at run-time to find the location
 of each entry.
 
 
+Compression
+-----------
+
+Binman support compression for 'blob' entries (those of type 'blob' and
+derivatives). To enable this for an entry, add a 'compression' property:
+
+    blob {
+        filename = "datafile";
+        compression = "lz4";
+    };
+
+The entry will then contain the compressed data, using the 'lz4' compression
+algorithm. Currently this is the only one that is supported.
+
+
+
 Map files
 ---------
 
@@ -672,6 +723,12 @@ If you need to specify a particular device-tree compiler to use, you can define
 the DTC environment variable. This can be useful when the system dtc is too
 old.
 
+To enable a full backtrace and other debugging features in binman, pass
+BINMAN_DEBUG=1 to your build:
+
+   make sandbox_defconfig
+   make BINMAN_DEBUG=1
+
 
 History / Credits
 -----------------