Olimex Support Forum

OLinuXino Android / Linux boards and System On Modules => A20 => Topic started by: leonardo.taglialegne on June 19, 2017, 12:48:15 PM

Title: Lime2 fails to reboot with u-boot mainline + sunxi-next
Post by: leonardo.taglialegne on June 19, 2017, 12:48:15 PM
I've compiled both u-boot and the kernel from the defconfig (with minimal adjustments for adding squashfs to the kernel, everything else untouched).

It boots and works fine, but when I try to reboot it hangs while displaying the "DRAM: 1GB" line.

It shows "DR" and then hangs there, no output from UART and nothing else happens (tried leaving it there for >30mins).

Any clues on what might have gone wrong?
Should I simply use legacy u-boot and be done with it? (will it boot a sunxi-next kernel?)
Title: Re: Lime2 fails to reboot with u-boot mainline + sunxi-next
Post by: LubOlimex on June 19, 2017, 03:00:54 PM
What type of reset is that? Soft reset via command or hard reset via the button?

Give a try to the mainline image of Armbian to determine if it is caused by the kernel itself or the rest of the settings.
Title: Re: Lime2 fails to reboot with u-boot mainline + sunxi-next
Post by: leonardo.taglialegne on June 19, 2017, 05:14:18 PM
Soft reset via "reboot" command.

Using armbian I can reboot fine, so I guess it's something in either the version or configuration I'm using.

Do you know where can I find the exact versions and configurations that armbian is using?
Title: Re: Lime2 fails to reboot with u-boot mainline + sunxi-next
Post by: igorpec on June 19, 2017, 09:21:57 PM
QuoteShould I simply use legacy u-boot and be done with it? (will it boot a sunxi-next kernel?)

Legacy u-boot won't boot mainline kernel properly ... but here as I understand it hangs at u-boot / SPL stage.

We use upstream u-boot v2017.05 with stock config + those patches https://github.com/armbian/build/tree/master/patch/u-boot/u-boot-sunxi

Take a quick look if you find something relevant to this problem. I think I saw this problem before on some other A20 board, but can't recall what was the solution.
Title: Re: Lime2 fails to reboot with u-boot mainline + sunxi-next
Post by: leonardo.taglialegne on June 22, 2017, 06:59:45 PM
Uhm, further tests show that even armbian's u-boot hangs at the same stage.

Any further ideas or tests to try?
Title: Re: Lime2 fails to reboot with u-boot mainline + sunxi-next
Post by: mrmajestyk on July 29, 2017, 12:04:44 AM
I am experiencing the same issue - though not consistently. Four out of five times or so, the board will soft boot OK but then a hang will occur. This makes the board a little bit awkward unfortunately.

I have tried different versions of U-boot, but it seems this error actually occurs before hand-off to U-boot, so I really don't know how to fix this. I would be very interested to hear of any solutions out there.
Title: Re: Lime2 fails to reboot with u-boot mainline + sunxi-next
Post by: igorpec on August 06, 2017, 05:26:00 PM
Quote from: mrmajestyk on July 29, 2017, 12:04:44 AM
I am experiencing the same issue - though not consistently. Four out of five times or so, the board will soft boot OK but then a hang will occur. This makes the board a little bit awkward unfortunately.

I have tried different versions of U-boot, but it seems this error actually occurs before hand-off to U-boot, so I really don't know how to fix this. I would be very interested to hear of any solutions out there.

Perhaps experimenting with DRAM_CLK might be a good way to go ?
https://github.com/RobertCNelson/u-boot/blob/master/configs/A20-OLinuXino-Lime2_defconfig#L4