ChanServ changed the topic of #linux-sunxi to: Allwinner/sunxi development - Did you try looking at our wiki? https://linux-sunxi.org - Don't ask to ask. Just ask and wait for an answer! - This channel is logged at https://oftc.irclog.whitequark.org/linux-sunxi
<apritzel> smaeul: I moved the SPL stack to below the save area
<apritzel> this is actually a bug in U-Boot for the H616: we place the SPL stack at the end of SRAM C (0x58000), but the BROM's FEL routine uses some bytes at 0x57d00
<apritzel> but I am still scratching my head why this didn't explode earlier, my best theory is that this area is not used for the FEL return, or it is re-initialised
<apritzel> I definitely see the BROM code for clearing 0x57d00-0x58000, near the beginning of the FEL entry point
<smaeul> this may be the secure monitor stack?
<smaeul> or the scratch area used by SBROM. it's been a long while since I looked at H616 BROM, but I remember there was code in NBROM to wipe SRAM used by SBROM
aggi has quit [Quit: connection closed.]
<apritzel> I see, clearing this area would someone explain it, although I would expect this to be done by the SBROM.
<apritzel> I also see some pointers to the first few words of this area, so there is some usage, but maybe not in the code path we are using
Danct12 has quit [Remote host closed the connection]
Danct12 has joined #linux-sunxi
<apritzel> smaeul: what AArch64 toolchain do you use? Can you FEL boot the OrangePi Zero2?
apritzel has quit [Ping timeout: 480 seconds]
sunshavi_ has quit []
sunshavi has joined #linux-sunxi
cnxsoft has joined #linux-sunxi
<smaeul> apritzel: gcc version 11.1.0 (GCC) // Trying to boot from FEL // usb_bulk_send() ERROR -7: Operation timed out
<smaeul> with "gcc version 10.1.0 (GCC)" and both current U-Boot master and with 38be6b838780 + f43312c974ea + c629ba854f2e, return to FEL works, and running TF-A works, but it gets stuck before the U-Boot proper banner
<smaeul> oh, nevermind on the getting stuck. I had patched my sunxi-fel to support 32-bit FIT loading in a way that broke 64-bit FIT loading. so gcc 10.1.0 works fine
<smaeul> http://ix.io/3Z3C verifies that we do get back to 32-bit mode even with newer GCC
cnxsoft has quit [Remote host closed the connection]
cnxsoft has joined #linux-sunxi
hexdump0815 has joined #linux-sunxi
hexdump01 has quit [Ping timeout: 480 seconds]
jernej_ has joined #linux-sunxi
jernej has quit [Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net]
<smaeul> gcc 11 works if I mark mctl_phy_read_calibration as noinline
megi has quit [Remote host closed the connection]
megi has joined #linux-sunxi
cnxsoft has quit []
indy_ has joined #linux-sunxi
indy has quit [Read error: Connection reset by peer]
JohnDoe_71Rus has joined #linux-sunxi
apritzel has joined #linux-sunxi
indy_ is now known as indy
apritzel has quit [Ping timeout: 480 seconds]
bauen1 has quit [Ping timeout: 480 seconds]
bauen1 has joined #linux-sunxi
rajkosto has quit [Read error: Connection reset by peer]
cnxsoft has joined #linux-sunxi
bauen1 has quit [Ping timeout: 480 seconds]
bauen1 has joined #linux-sunxi
apritzel has joined #linux-sunxi
bauen1 has quit [Ping timeout: 480 seconds]
<apritzel> smaeul: ah, many thanks for the confirmation and the extra tests, some nice new puzzle pieces ;-)
bauen1 has joined #linux-sunxi
user6476 has quit []
<apritzel> cyrozap: I was wondering if you could add a udelay(1); at the beginning and the end of mctl_phy_read_calibration(), to see if the aggressive inlining is too fast for the DRAM controller
<apritzel> I am still scratching my head about how some DRAM code problem could spoil the return to FEL, if apparently we get to the very end of the SPL just fine
indy has quit [Ping timeout: 480 seconds]
indy has joined #linux-sunxi
ftg has joined #linux-sunxi
JohnDoe_71Rus has quit []
bauen1 has quit [Ping timeout: 480 seconds]
vagrantc has joined #linux-sunxi
cnxsoft has quit []
cnxsoft has joined #linux-sunxi
cnxsoft has quit []
JohnDoe_71Rus has joined #linux-sunxi
bauen1 has joined #linux-sunxi
bauen1_ has joined #linux-sunxi
bauen1 has quit [Ping timeout: 480 seconds]
adjtm has joined #linux-sunxi
adjtm has quit []
apritzel has quit [Ping timeout: 480 seconds]
JohnDoe_71Rus has quit []
evgeny_boger has joined #linux-sunxi
apritzel has joined #linux-sunxi
hlauer has joined #linux-sunxi
evgeny_boger1 has joined #linux-sunxi
evgeny_boger1 has quit [Remote host closed the connection]
evgeny_boger has quit [Ping timeout: 480 seconds]
Hypfer has quit [Quit: The Lounge - https://thelounge.github.io]
Hypfer has joined #linux-sunxi
<apritzel> cyrozap, smaeul: putting a udelay(0); (yes, 0) at the beginning of mctl_phy_read_calibration() also fixes it for me
<apritzel> I wonder if this is a barrier problem, because GCC too aggressively reorders the code. And we have no barriers in place for the clrsetbits() calls
sunshavi has quit [Ping timeout: 480 seconds]
sunshavi has joined #linux-sunxi
hlauer has quit [Ping timeout: 480 seconds]
pmp-p has quit [Ping timeout: 480 seconds]
pmp-p has joined #linux-sunxi