<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/examples/api, branch v2026.04-rc5</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<entry>
<title>examples: fix building on arm32</title>
<updated>2025-02-04T17:57:36+00:00</updated>
<author>
<name>Liya Huang</name>
<email>1425075683@qq.com</email>
</author>
<published>2025-01-28T01:13:16+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=5cf9e61f0fa984c86d2ec59c843cd7b4c6220d34'/>
<id>5cf9e61f0fa984c86d2ec59c843cd7b4c6220d34</id>
<content type='text'>
Refer to the commit a3c101a61348 ("examples: fix building on arm64")
fix for arm32. crt0.S does not even build with:
    operating system and architecture:
        5.15.0-130-generic x86_64
    installed version of gcc and binutils:
        gcc version 9.4.0 (Ubuntu 9.4.0-1ubuntu1~20.04.3)
    GNU ld (GNU Binutils for Ubuntu) 2.34
    used defconfig:
        stm32h750-art-pi_defconfig
    used commands for building:
        export CROSS_COMPILE=arm-none-eabi- ARCH=arm
        make stm32h750-art-pi_defconfig
        make menuconfig # to add
        make
    examples/api/crt0.S: Assembler messages:
    examples/api/crt0.S:32: Error: lo register required -- `ldr ip,=search_hint'
    examples/api/crt0.S:33: Error: lo register required -- `str sp,[ip]'
    examples/api/crt0.S:39: Error: lo register required -- `ldr ip,=syscall_ptr'
    examples/api/crt0.S:40: Error: lo register required -- `ldr pc,[ip]'
    make[2]: *** [scripts/Makefile.build:292：examples/api/crt0.o] Error 1

Use valid register names and instructions.

Signed-off-by: Liya Huang &lt;1425075683@qq.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Refer to the commit a3c101a61348 ("examples: fix building on arm64")
fix for arm32. crt0.S does not even build with:
    operating system and architecture:
        5.15.0-130-generic x86_64
    installed version of gcc and binutils:
        gcc version 9.4.0 (Ubuntu 9.4.0-1ubuntu1~20.04.3)
    GNU ld (GNU Binutils for Ubuntu) 2.34
    used defconfig:
        stm32h750-art-pi_defconfig
    used commands for building:
        export CROSS_COMPILE=arm-none-eabi- ARCH=arm
        make stm32h750-art-pi_defconfig
        make menuconfig # to add
        make
    examples/api/crt0.S: Assembler messages:
    examples/api/crt0.S:32: Error: lo register required -- `ldr ip,=search_hint'
    examples/api/crt0.S:33: Error: lo register required -- `str sp,[ip]'
    examples/api/crt0.S:39: Error: lo register required -- `ldr ip,=syscall_ptr'
    examples/api/crt0.S:40: Error: lo register required -- `ldr pc,[ip]'
    make[2]: *** [scripts/Makefile.build:292：examples/api/crt0.o] Error 1

Use valid register names and instructions.

Signed-off-by: Liya Huang &lt;1425075683@qq.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples/api: improve determination of LOAD_ADDR</title>
<updated>2025-02-04T17:57:36+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2025-01-27T06:49:36+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=1df9cbd70f56bdbb3b8b004d51c8eea7379a28b2'/>
<id>1df9cbd70f56bdbb3b8b004d51c8eea7379a28b2</id>
<content type='text'>
The current load address for the 'demo' binary does not work for
qemu_arm_defconfig.

The suitability of an address to load an ELF binary and run it does
not only depend on the architecture but also on the memory layout of
the board.

On most boards we can assume that 8 MiB of memory is available above
$loadaddr. So $loadaddr + 0x400000 should work there.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The current load address for the 'demo' binary does not work for
qemu_arm_defconfig.

The suitability of an address to load an ELF binary and run it does
not only depend on the architecture but also on the memory layout of
the board.

On most boards we can assume that 8 MiB of memory is available above
$loadaddr. So $loadaddr + 0x400000 should work there.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: use QEMU compatible LOAD_ADDR on RISC-V</title>
<updated>2025-01-05T01:30:47+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2024-11-23T08:47:54+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=8e5b57eea04c80a9226c6c71f892c8808caa3d65'/>
<id>8e5b57eea04c80a9226c6c71f892c8808caa3d65</id>
<content type='text'>
On some RISC-V including QEMU $loadaddr is 0x80200000.
For bootelf to work choose a different LOAD_ADDR to which the demo ELF
binary is relocated.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On some RISC-V including QEMU $loadaddr is 0x80200000.
For bootelf to work choose a different LOAD_ADDR to which the demo ELF
binary is relocated.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: use architecture specific memset() on RISC-V</title>
<updated>2025-01-05T01:30:47+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2024-11-23T08:47:53+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=e18186686fc6c4f1b7ef04a5f77b74fcd44cb721'/>
<id>e18186686fc6c4f1b7ef04a5f77b74fcd44cb721</id>
<content type='text'>
Build the architecture specific memset() if configured.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Build the architecture specific memset() if configured.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: implement _start and syscall for RISC-V</title>
<updated>2025-01-05T01:30:47+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2024-11-23T08:47:52+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=9eb59201ab60b7ca3af41cd3000f8ff823ae5f02'/>
<id>9eb59201ab60b7ca3af41cd3000f8ff823ae5f02</id>
<content type='text'>
To build the API examples on RISC-V we need to
implement _start and syscall for RISC-V.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
To build the API examples on RISC-V we need to
implement _start and syscall for RISC-V.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: make glue and demo code compatible with 64-bit</title>
<updated>2024-11-14T16:51:07+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2024-11-03T05:35:51+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=9e7d7f95ecfe0dd94b17c8dddff0e9f4934c2ad2'/>
<id>9e7d7f95ecfe0dd94b17c8dddff0e9f4934c2ad2</id>
<content type='text'>
Commit f9886bc60f42 ("Added arm64 assembly for examples/api crt0")
added a 64-bit target for the examples but did not adjust the demo
code to be 64-bit compatible.

Change variable size for pointers.
Use %p to print pointers.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit f9886bc60f42 ("Added arm64 assembly for examples/api crt0")
added a 64-bit target for the examples but did not adjust the demo
code to be 64-bit compatible.

Change variable size for pointers.
Use %p to print pointers.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: adjust LOAD_ADDR on arm64</title>
<updated>2024-11-14T16:51:07+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2024-11-03T05:35:50+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=2ed26ee37472d48d04cf9c6cc7c3be806d06a900'/>
<id>2ed26ee37472d48d04cf9c6cc7c3be806d06a900</id>
<content type='text'>
Change the load address on arm64 such that it is compatible with the memory
available on qemu_arm64_defconfig.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change the load address on arm64 such that it is compatible with the memory
available on qemu_arm64_defconfig.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: fix building on arm64</title>
<updated>2024-11-14T16:51:07+00:00</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2024-11-03T05:35:49+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=a3c101a613481ecc7286e1949e6aa97474c7a4fe'/>
<id>a3c101a613481ecc7286e1949e6aa97474c7a4fe</id>
<content type='text'>
Commit f9886bc60f42 ("Added arm64 assembly for examples/api crt0") tried to
add arm64 support to the examples but crt0.S does not even build for
qemu_arm64_defconfig with CONFIG_API=y, CONFIG_EXAMPLES=y:

    examples/api/crt0.S: Assembler messages:
    examples/api/crt0.S:32: Error:
        expected a register at operand 1 -- `ldr ip,=search_hint'
    examples/api/crt0.S:33: Error:
        unexpected register type at operand 1 -- `str sp,[ip]'
    make[2]: *** [scripts/Makefile.build:292: examples/api/crt0.o] Error 1

Do not define _start twice.
Use valid register names.
Move syscall_ptr and search_hint to the data section to avoid an invalid
relocation.

Fixes: f9886bc60f42 ("Added arm64 assembly for examples/api crt0")
Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit f9886bc60f42 ("Added arm64 assembly for examples/api crt0") tried to
add arm64 support to the examples but crt0.S does not even build for
qemu_arm64_defconfig with CONFIG_API=y, CONFIG_EXAMPLES=y:

    examples/api/crt0.S: Assembler messages:
    examples/api/crt0.S:32: Error:
        expected a register at operand 1 -- `ldr ip,=search_hint'
    examples/api/crt0.S:33: Error:
        unexpected register type at operand 1 -- `str sp,[ip]'
    make[2]: *** [scripts/Makefile.build:292: examples/api/crt0.o] Error 1

Do not define _start twice.
Use valid register names.
Move syscall_ptr and search_hint to the data section to avoid an invalid
relocation.

Fixes: f9886bc60f42 ("Added arm64 assembly for examples/api crt0")
Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: Remove duplicate newlines</title>
<updated>2024-07-15T18:12:17+00:00</updated>
<author>
<name>Marek Vasut</name>
<email>marek.vasut+renesas@mailbox.org</email>
</author>
<published>2024-07-13T13:19:20+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=73a48dc856b57aecee4ff69dd1325d1f3074405c'/>
<id>73a48dc856b57aecee4ff69dd1325d1f3074405c</id>
<content type='text'>
Drop all duplicate newlines. No functional change.

Signed-off-by: Marek Vasut &lt;marek.vasut+renesas@mailbox.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Drop all duplicate newlines. No functional change.

Signed-off-by: Marek Vasut &lt;marek.vasut+renesas@mailbox.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Added arm64 assembly for examples/api crt0</title>
<updated>2024-06-07T22:23:05+00:00</updated>
<author>
<name>Brunham, Kalen</name>
<email>kalen.brunham@intel.com</email>
</author>
<published>2024-05-17T19:13:48+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=f9886bc60f42d5bcfcfa4e474af7dc230400b6be'/>
<id>f9886bc60f42d5bcfcfa4e474af7dc230400b6be</id>
<content type='text'>
I've encountered a problem when compiling the 'examples/api' directory for ARM64 in U-boot. The problem lies in the assembly code in 'examples/api/crt0.S' where the current CONFIG_ARM code is only 32-bit. When targeting ARM64, a 64-bit version is necessary.

I have proposed a fix by including a 'CONFIG_ARM64' section in the assembly code as shown below.  These changes have been check via https://github.com/u-boot/u-boot/pull/538.

Feedback is welcome.

Signed-off-by: Kalen Brunham &lt;kalen.brunham@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I've encountered a problem when compiling the 'examples/api' directory for ARM64 in U-boot. The problem lies in the assembly code in 'examples/api/crt0.S' where the current CONFIG_ARM code is only 32-bit. When targeting ARM64, a 64-bit version is necessary.

I have proposed a fix by including a 'CONFIG_ARM64' section in the assembly code as shown below.  These changes have been check via https://github.com/u-boot/u-boot/pull/538.

Feedback is welcome.

Signed-off-by: Kalen Brunham &lt;kalen.brunham@intel.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
