[PATCH master 1/3] RISC-V: cpu: request stack memory region
Ahmad Fatoum
a.fatoum at pengutronix.de
Sat Apr 3 08:09:15 BST 2021
Hello Antony,
On 02.04.21 10:13, Antony Pavlov wrote:
>> This is strange. Could you print get_runtime_offset() at this location?
>> It should be zero, because relocate_to_current_adr() had previously run,
>> but it seems it's not for you? I don't see how compiler reordering could have
>> occurred given that we don't do LTO and relocate_to_current_adr is thus
>> a compiler barrier.
[ Naïve me thinking there are any guarantees from GCC for self-modifying code ]
> + empty_slot_init(0, 0xffffffff);
That's tremendously useful. Thanks! I don't quite understand how it works
though. It registers a "fall-back" device for all of the 32-bit address
space?
> There are empty_slot read warnings on master:
>
> barebox$ qemu-system-riscv32 -nographic -M erizo -bios ./images/barebox-erizo-generic.img -serial stdio -monitor none -trace file=/dev/null
> >get_runtime_offset()=0x00000000
> empty_slot: read from 0000000000022caf
> empty_slot: read from 0000000000022cae
> empty_slot: read from 0000000000022cb0
> empty_slot: read from 0000000000022cb1
> riscv-timer riscv-timer: running at 24000000 Hz
> Switch to console [cs0]
>
> barebox 2021.03.0-00134-gc4a1684da9-dirty #1 Fri Apr 2 10:33:45 MSK 2021
>
> Board: generic Erizo SoC board
> riscv-timer riscv-timer: running at 24000000 Hz
> malloc space: 0x804ffd80 -> 0x805ffd7f (size 1 MiB)
>
> Hit any to stop autoboot: 1
> boot: error 2
> barebox:/
>
>
> There is no empty_slot warning with fef19e17f651^ barebox:
>
> barebox$ qemu-system-riscv32 -nographic -M erizo -bios ./images/barebox-erizo-generic.img -serial stdio -monitor none -trace file=/dev/null
> >RISC-V system with no 'timebase-frequency' in DTS
> Switch to console [cs0]
>
> barebox 2021.03.0-00122-g6107208573 #1 Fri Apr 2 11:09:16 MSK 2021
>
> Board: generic Erizo SoC board
> RISC-V system with no 'timebase-frequency' in DTS
> malloc space: 0x802ffd80 -> 0x803ffd7f (size 1 MiB)
>
> Hit any to stop autoboot: 0
> boot: error 2
> barebox:/
Thanks. I identified two issues and CC'd you on a patch fixing them.
Breaking erizo has been a blessing to sort out this kind of bugs early :D
Cheers,
Ahmad
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the barebox
mailing list