RFC U-Boot LTO (Sandbox + ARM Nokia RX-51)
Get series with b4
b4 am 20210509204457.50f17b41@thinkpadVersions newest first
- v1 RFC Latest0 of 12 patches 0 repliesNew
Patches in v1 No applies recorded yet
None of the 12 patches the cover letter announces are in this archive.
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [RFC PATCH u-boot 00/12] U-Boot LTO (Sandbox + ARM Nokia RX-51)
Quoted 134 lines · On Sun, 9 May 2021 09:14:14 -0500 Adam Ford <[email protected]> wrote:
Quoted 133 lines · Marek Behun
Quoted 129 lines · On Sat, 6 Mar 2021 21:45:02 -0600 Adam Ford <[email protected]> wrote:
Quoted 90 lines · Marek Behun
Quoted 86 lines · On Sat, 6 Mar 2021 22:38:52 +0100 Pali Roh?r <[email protected]> wrote:
Quoted 58 lines · On Saturday 06 March 2021 22:19:22 Marek Behun wrote:
Quoted 55 lines · On Sat, 6 Mar 2021 22:00:45 +0100 Pali Roh?r <[email protected]> wrote:
Quoted 9 lines · On Saturday 06 March 2021 21:54:00 Marek Behun wrote:
Quoted 6 lines · On Sat, 6 Mar 2021 21:41:14 +0100 Pali Roh?r <[email protected]> wrote:
Quoted 2 lines · On Saturday 06 March 2021 15:08:13 Tom Rini wrote:
Perhaps we'll default to yes on some SoCs. The omap3 thing is a bit odd, but we'll see what happens on real N900 hardware.
Hello!
Quoted 8 lines
Quoted 6 lines
Could you send me a link to git repo / branch and tell me from which commit should I do tests on real N900 hardware? I will test it and let you know results.
Adding maemo ML to the loop as on the maemo list are more people with N900 HW and U-Boot.
https://github.com/elkablo/u-boot branch lto
Sorry, compilation is failing :-(
$ git clone https://github.com/elkablo/u-boot -b lto --depth=100 Cloning into 'u-boot'... remote: Enumerating objects: 33644, done. remote: Counting objects: 100% (33644/33644), done. remote: Compressing objects: 100% (20116/20116), done. remote: Total 33644 (delta 15838), reused 19947 (delta 13018), pack-reused 0 Receiving objects: 100% (33644/33644), 26.28 MiB | 10.21 MiB/s, done. Resolving deltas: 100% (15838/15838), done.$ cd u-boot$ make CROSS_COMPILE=arm-linux-gnueabi- nokia_rx51_config HOSTCC scripts/basic/fixdep HOSTCC scripts/kconfig/conf.o YACC scripts/kconfig/zconf.tab.c LEX scripts/kconfig/zconf.lex.c HOSTCC scripts/kconfig/zconf.tab.o HOSTLD scripts/kconfig/conf # # configuration written to .config #$ make CROSS_COMPILE=arm-linux-gnueabi- u-boot.bin ... LTO u-boot /usr/lib/gcc-cross/arm-linux-gnueabi/8/../../../../arm-linux-gnueabi/bin/ld: /usr/lib/gcc-cross/arm-linux-gnueabi/8/../../../../arm-linux-gnueabi/bin/ld: DWARF error: offset (1258291444) greater than or equal to .debug_str size (676) /usr/lib/gcc-cross/arm-linux-gnueabi/8/../../../../arm-linux-gnueabi/bin/ld: DWARF error: offset (1459618036) greater than or equal to .debug_str size (676) /usr/lib/gcc-cross/arm-linux-gnueabi/8/../../../../arm-linux-gnueabi/bin/ld: DWARF error: could not find abbrev number 48028 /tmp/cc8l0QSQ.ltrans3.ltrans.o: in function `omap3_set_aux_cr_secure': <artificial>:(.text+0x6eb8): undefined reference to `do_omap3_emu_romcode_call' collect2: error: ld returned 1 exit status make: *** [Makefile:1808: u-boot] Error 1Quoted 5 lines
Quoted 2 lines
I'm using arm-linux-gnueabi-gcc version 8.3.0 which is available in current Debian stable (Debian 10 Buster).
Fixed and force-pushed, it seems ar needs the P flag that Bin Meng questioned.
Problem is fixed, now compilation succeeded. u-boot.bin has size 243788 bytes.
And seems that compiled U-Boot is working fine!
Nokia RX-51 # version
U-Boot 2021.04-rc3-00338-g88d0a5042c97 (Mar 06 2021 - 22:19:08 +0100)arm-linux-gnueabi-gcc (Debian 8.3.0-2) 8.3.0
GNU ld (GNU Binutils for Debian) 2.31.1I can send binary files via usbtty and 'loadb' command. I can boot linux kernel via 'bootm'. I can chainload to another U-Boot binary (loaded by 'loadb') via 'go' command. Also 'ext4ls' and 'fatls' commands are working. Also 'onenand dump bootloader' is working.
Do you need something more to test?
If not you can add my 'Tested-by: Pali Roh?r <[email protected]>' line for all patches which are up to the commit
88d0a5042c97.Quoted 9 lines
Quoted 1 line
Good job!
Thanks.
I am still working on these patches, since I have discovered some more defconfigs which fail to build for one reason or another.
I will send a patch enabling LTO for Nokia N900 though.
I have my DM3730 booting now
arch/arm/mach-omap2/omap3/Makefile +2
-0@@ -6,6 +6,8 @@ # If clock.c is compiled for Thumb2, then it fails on OMAP3530 CFLAGS_clock.o += -marm +CFLAGS_REMOVE_board.o := $(LTO_CFLAGS) + obj-y := lowlevel_init.o obj-y += board.oThe
board.cfile has a few functions with assembly code and some functions called by assembly. I wonder if there needs to be some compiler flags added to it to ensure it boots. I am not as experienced with compiler directives andMakefiletweaks, but I am willing to try stuff if people have suggestions.However, at least for now, the
omap3_logicboard works. I haven't tried the AM3517 yet. It's similar to the omap3 with a different memory controller so I'm more concerned about it than the OMAP3530. If I have time tomorrow, I'll run some tests on the AM3517.
Quoted 9 lines
Quoted 3 lines
Quoted 1 line
adam
Adding to my patches, thanks.
Do you think you'll be re-submitting any of this for the next release of U-Boot? I felt like we had some good momentum going.
Quoted 2 lines
Marek
I shall look into this again this week. There is one problem I discovered last month and haven't yet time to look into it. It is pretty important - network does not work with the mvneta driver on Turris Omnia when compiled with LTO...
Marek