1. 12 11月, 2019 1 次提交
    • S
      binman: tegra: Adjust symbol calculation depending on end-at-4gb · 7c150136
      Simon Glass 提交于
      A recent change adjusted the symbol calculation to work on x86 but broke
      it for Tegra. In fact this is because they have different needs.
      
      On x86 devices the code is linked to a ROM address and the end-at-4gb
      property is used for the image. In this case there is no need to add the
      base address of the image, since the base address is already built into
      the offset and image-pos properties.
      
      On other devices we must add the base address since the offsets start at
      zero.
      
      In addition the base address is currently added to the 'offset' and 'size'
      values. It should in fact only be added to 'image-pos', since 'offset' is
      relative to its parent and 'size' is not actually an address. This code
      should have been adjusted when support for 'image-pos' and 'size' was
      added, but it was not.
      
      To correct these problems:
      - move the code that handles adding the base address to section.py, which
        can check the end-at-4gb property and which property
        (offset/size/image-pos) is being read
      - add the base address only when needed (only for image-pos and not if the
        image uses end-at-4gb)
      - add a note to the documentation
      - add a separate test to cover x86 behaviour
      
      Fixes: 15c981cc (binman: Correct symbol calculation with non-zero image base)
      Signed-off-by: NSimon Glass <sjg@chromium.org>
      Tested-by: NStephen Warren <swarren@nvidia.com>
      7c150136
  2. 11 10月, 2019 1 次提交
  3. 08 10月, 2019 1 次提交
  4. 29 7月, 2019 6 次提交
  5. 25 7月, 2019 10 次提交
  6. 24 7月, 2019 5 次提交
  7. 11 7月, 2019 1 次提交
  8. 08 5月, 2019 1 次提交
  9. 21 11月, 2018 1 次提交
  10. 30 9月, 2018 4 次提交
  11. 29 9月, 2018 1 次提交
  12. 28 9月, 2018 1 次提交
    • J
      binman: Add a new "skip-at-start" property in Section class · 94b57db0
      Jagdish Gediya 提交于
      Currently binman calculates '_skip_at_start' based on 'end-at-4gb'
      property and it is used for x86 images.
      
      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, so "_skip_at_start"
      should be set to CONFIG_SYS_TEXT_BASE.
      
      'end-at-4gb' property is not applicable where CONFIG_SYS_TEXT_BASE +
      Image size != 4gb.
      
      Add new property 'skip-at-start' in Section class so that
      '_skip_at_start' can be calculated either based on 'end-at-4gb'
      or based on "skip-at-start".
      
      Add a test case to check that 'skip-at-start' and 'end-at-4gb'
      property can't be used together.
      Signed-off-by: NJagdish Gediya <jagdish.gediya@nxp.com>
      Reviewed-by: NBin Meng <bmeng.cn@gmail.com>
      Reviewed-by: NSimon Glass <sjg@chromium.org>
      Reviewed-by: NYork Sun <york.sun@nxp.com>
      94b57db0
  13. 18 9月, 2018 1 次提交
  14. 02 8月, 2018 5 次提交
    • S
      binman: Create README.entries · 5a5da7ce
      Simon Glass 提交于
      Create a new README containing documentation for the entry types supported
      by binman. This provides an easy reference in one place. It is
      automatically generated from the source-code documentation.
      
      Add a reference to this from the binman README.
      Signed-off-by: NSimon Glass <sjg@chromium.org>
      5a5da7ce
    • S
      binman: Add support for passing arguments to entries · 53af22a9
      Simon Glass 提交于
      Sometimes it is useful to pass binman the value of an entry property from
      the command line. For example some entries need access to files and it is
      not always convenient to put these filenames in the image definition
      (device tree).
      
      Add a -a option which can be used like this:
      
         -a<prop>=<value>
      
      where
      
         <prop> is the property to set
         <value> is the value to set it to
      Signed-off-by: NSimon Glass <sjg@chromium.org>
      53af22a9
    • S
      binman: Add a new 'image-pos' property · dbf6be9f
      Simon Glass 提交于
      At present each entry has an offset within its parent section. This is
      useful for figuring out how entries relate to one another. However it
      is sometimes necessary to locate an entry within an image, regardless
      of which sections it is nested inside.
      
      Add a new 'image-pos' property to provide this information. Also add
      some documentation for the -u option binman provides, which updates the
      device tree with final entry information.
      
      Since the image position is a better symbol to use for the position of
      U-Boot as obtained by SPL, update the SPL symbols to use this instead of
      offset, which might be incorrect if hierarchical sections are used.
      Signed-off-by: NSimon Glass <sjg@chromium.org>
      dbf6be9f
    • S
      binman: Enhance the map and fdt-update output · 8122f396
      Simon Glass 提交于
      At present the .map file produced for each image does not include the
      overall image size. This is useful information.
      
      Update the code to generate it in the .map file as well as the updated
      FDT. Also fix a few comments while we are here.
      Signed-off-by: NSimon Glass <sjg@chromium.org>
      8122f396
    • S
      binman: Rename 'position' to 'offset' · 3ab9598d
      Simon Glass 提交于
      After some thought, I believe there is an unfortunate naming flaw in
      binman. Entries have a position and size, but now that we support
      hierarchical sections it is unclear whether a position should be an
      absolute position within the image, or a relative position within its
      parent section.
      
      At present 'position' actually means the relative position. This indicates
      a need for an 'image position' for code that wants to find the location of
      an entry without having to do calculations back through parents to
      discover this image position.
      
      A better name for the current 'position' or 'pos' is 'offset'. It is not
      always an absolute position, but it is always an offset from its parent
      offset.
      
      It is unfortunate to rename this concept now, 18 months after binman was
      introduced. However I believe it is the right thing to do. The impact is
      mostly limited to binman itself and a few changes to in-tree users to
      binman:
      
         tegra
         sunxi
         x86
      
      The change makes old binman definitions (e.g. downstream or out-of-tree)
      incompatible if they use the 'pos = <...>' property. Later work will
      adjust binman to generate an error when it is used.
      Signed-off-by: NSimon Glass <sjg@chromium.org>
      3ab9598d
  15. 09 7月, 2018 1 次提交