<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/tools/binman/test/Makefile, branch v2022.04</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/u-boot.git/atom/tools/binman/test/Makefile?h=v2022.04</id>
<link rel='self' href='http://cgit.235523.xyz/u-boot.git/atom/tools/binman/test/Makefile?h=v2022.04'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<updated>2022-02-22T17:05:44Z</updated>
<entry>
<title>binman: Add a ELF test file with disjoint text sections</title>
<updated>2022-02-22T17:05:44Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2022-02-08T18:49:59Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=56385c585fa5c51aacfd7ffa8021ea705c715b6f'/>
<id>urn:sha1:56385c585fa5c51aacfd7ffa8021ea705c715b6f</id>
<content type='text'>
Add a file that has two text sections at different addresses, so we can
test this behaviour in binman, once added.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: Support updating the dtb in an ELF file</title>
<updated>2021-11-13T15:16:39Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2021-11-04T03:09:18Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=0427bed63bece3caeb8153548903146b73b56677'/>
<id>urn:sha1:0427bed63bece3caeb8153548903146b73b56677</id>
<content type='text'>
WIth EFI we must embed the devicetree in an ELF image so that it is loaded
as part of the executable file. We want it to include the binman
definition in there also, which in some cases cannot be created until the
ELF (u-boot) is built. Add an option to binman to support writing the
updated dtb to the ELF file u-boot.out

This is useful with the EFI app, which is always packaged as an ELF file.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: Support reading the offset of an ELF-file symbol</title>
<updated>2021-11-13T15:16:39Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2021-11-04T03:09:16Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=056f0efd8ba20f382f120262c632545e6f06b4a5'/>
<id>urn:sha1:056f0efd8ba20f382f120262c632545e6f06b4a5</id>
<content type='text'>
Binman needs to be able to update the contents of an ELF file after it has
been build. To support this, add a function to locate the position of a
symbol's contents within the file.

Fix the comments on bss_data.c and Symbol while we are here.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: Support cross-compiling test files to x86</title>
<updated>2020-09-22T18:54:13Z</updated>
<author>
<name>Alper Nebi Yasak</name>
<email>alpernebiyasak@gmail.com</email>
</author>
<published>2020-09-06T11:46:04Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=5ac7687827d5b414bd26ceb7de17e7a14490af34'/>
<id>urn:sha1:5ac7687827d5b414bd26ceb7de17e7a14490af34</id>
<content type='text'>
These test files are currently "intended for use on x86 hosts", but most
of the tests using them can still pass when cross-compiled to x86 on an
arm64 host.

This patch enables non-x86 hosts to run the tests by specifying a
cross-compiler via CROSS_COMPILE. The list of variables it sets is taken
from the top-level Makefile. It would be possible to automatically set
an x86 cross-compiler with a few blocks like:

    ifneq ($(shell i386-linux-gnu-gcc --version 2&gt; /dev/null),)
    CROSS_COMPILE = i386-linux-gnu-
    endif

But it wouldn't propagate to the binman process calling this Makefile,
so it's better just raise an error and expect 'binman test' to be run
with a correct CROSS_COMPILE.

Signed-off-by: Alper Nebi Yasak &lt;alpernebiyasak@gmail.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: tegra: Adjust symbol calculation depending on end-at-4gb</title>
<updated>2019-11-11T19:20:35Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2019-11-07T00:22:44Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=7c150136398916ac546b5a902d09208cc793cabe'/>
<id>urn:sha1:7c150136398916ac546b5a902d09208cc793cabe</id>
<content type='text'>
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: Simon Glass &lt;sjg@chromium.org&gt;
Tested-by: Stephen Warren &lt;swarren@nvidia.com&gt;
</content>
</entry>
<entry>
<title>binman: Clean up unnecessary code related to ELF test files</title>
<updated>2019-10-15T14:40:02Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2019-08-24T13:22:59Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=c9a0b27589a49d4beaaa4f75500597ab07cfff39'/>
<id>urn:sha1:c9a0b27589a49d4beaaa4f75500597ab07cfff39</id>
<content type='text'>
We use the Makefile for all ELF test files now, so drop all the code that
checks whether to get the test file from the Makefile or from the git
repo.

Also add a comment to the Makefile indicating that it is run from binman.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: Use the Makefile for u_boot_binman_syms_bad</title>
<updated>2019-10-15T14:40:02Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2019-08-24T13:22:58Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=8dc60f99f9a2fe7873a753f1ab0254efd3cd6bd4'/>
<id>urn:sha1:8dc60f99f9a2fe7873a753f1ab0254efd3cd6bd4</id>
<content type='text'>
Remove this file from git and instead build it using the Makefile.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: Use the Makefile for u_boot_binman_syms</title>
<updated>2019-10-15T14:40:02Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2019-08-24T13:22:56Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=1542c8b5fce0f81ace585ac87218bfd79eb077f3'/>
<id>urn:sha1:1542c8b5fce0f81ace585ac87218bfd79eb077f3</id>
<content type='text'>
Remove this file from git and instead build it using the Makefile.

With this change a few things need to be adjusted:

1. The 'notes' section no-longer appears at the start of the ELF file
(before the code), so update testSymbols to adjust the offsets.

2. The dynamic linker is disabled to avoid errors like:

    "Not enough room for program headers, try linking with -N"

3. The interpreter note is moved to the end of the image, so that the
binman symbols appear first.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: Use the Makefile for u_boot_ucode_ptr</title>
<updated>2019-10-15T14:40:02Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2019-08-24T13:22:54Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=f514d8f23de4aada7e6f9f4d9de731b43912a77a'/>
<id>urn:sha1:f514d8f23de4aada7e6f9f4d9de731b43912a77a</id>
<content type='text'>
Remove this file from git and instead build it using the Makefile.

Update tools.GetInputFilename() to support reading files from an absolute
path, so that we can read the Elf test files easily. Also make sure that
the temp directory is report in ELF tests as this was commented out.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>binman: Use the Makefile to build ELF test files</title>
<updated>2019-10-15T14:40:02Z</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2019-08-24T13:22:53Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=53e22bf38c202d5ef3bc092d55095c672994a15b'/>
<id>urn:sha1:53e22bf38c202d5ef3bc092d55095c672994a15b</id>
<content type='text'>
At present the ELF test files are checked into the U-Boot tree. This is
covenient since the files never change and can be used on non-x86
platforms. However it is not good practice to check in binaries and in
this case it does not seem essential.

Update the binman test-file Makefile to support having source in a
different directory. Adjust binman to run it to build bss_data, as a
start. We can add other files as needed.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
</feed>
