[LIME2] Upstream U-Boot config outdated for recent revisions

Started by unicorn, December 12, 2019, 12:05:48 PM

Previous topic - Next topic

unicorn

Hello,

While getting OpenBSD to work on my T2 OLinuXino LIME2, I had some issues with U-Boot (eg. LAN didn't work) due to differences between the required config and upstream U-Boot. As far as I understood it thanks to the help of someone on the OpenBSD mailing list, my hardware revision (Rev K) uses a different LAN solution than previous versions, and the changes have not been upstreamed.

As a result, I had to manually change some config files and build the `u-boot-sunxi-with-spl.bin` myself, which is a bit of a tedious process and not a good way of supporting the board.

Are/were there any efforts from you to upstream this to mainline U-Boot? If that's not possible, could you make the files required more accessible and visible perhaps? Or am I missing something?

Even on the linux-sunxi wiki for the LIME2 there is mentions of a required config for new revisions, but the link does not lead to any page and there is no closer information.

Thanks in advance!

LubOlimex

Technical support and documentation manager at Olimex

mmn

Quote from: unicorn on December 12, 2019, 12:05:48 PMAs far as I understood it thanks to the help of someone on the OpenBSD mailing list, my hardware revision (Rev K) uses a different LAN solution than previous versions, and the changes have not been upstreamed.
Hi, could you please share a link to the relevant thread in the mailing list archive? I might be dealing with a similar problem.
Quote from: LubOlimex on December 13, 2019, 09:02:51 AMPlease check here: ftp://staging.olimex.com/Allwinner_Images/A20-OLinuXino/

and here: https://www.olimex.com/wiki/ArmbianHowTo
Could you please tell us about the u-boot mainlining status? Sure, Armbian is nice, but it would be really cool if we could install other distros (such as vanilla debian) or systems (such as OpenBSD as in OP's case) out of the box.

unicorn

Quote from: mmn on December 27, 2019, 12:14:17 PMcould you please share a link to the relevant thread in the mailing list archive? I might be dealing with a similar problem.
https://marc.info/?l=openbsd-arm&m=157193410630016&w=2
This is the thread with a bunch of information, I ended up using a binary that the person who helped me sent to me privately though, because I did not fully understand what some of the things he said were based on.

And I am with you on the second question, mainline was the goal of my question, not the link to the Olimex repository. I would like to hear about that and see progress too. :)

JimT

Same issue with Debian Buster at Rev. K (LAN not working).
 
Quote from: unicorn on December 12, 2019, 12:05:48 PMAs a result, I had to manually change some config files and build the `u-boot-sunxi-with-spl.bin` myself, which is a bit of a tedious process and not a good way of supporting the board.
Could you tell me/us how you did it?
I know there's a howto on the sunxis webpage, but if you just started with u-boot and so on it's quit hard to finish.

I have read about an alternative solutions, it's about reducing speed to e.g. 10 Mbit/s. I tried it with deb-packages on usb-stick, but couldn't get it to work :(

unicorn

Quote from: JimT on January 08, 2020, 06:24:20 PMCould you tell me/us how you did it?
Read through the email thread I posted above, somebody explained the process to me there, though with the example of OpenBSD.
There is also some information in the Armbian Howto that LubOlimex posted, that actually differs from the explanation I got on the mailing list though. I have to admit I did not confirm whether the process explained in the mailing list works, but the person who helped me provided a working binary for me to use, which worked perfectly.


I think the takeaway here is that there is clear demand for upstreaming these modifications or at least providing clearer information on how to get U-Boot working for whichever hardware revision you are using. I would really appreciate seeing this, Olimex!

JimT

I finally made it with a modified u-boot.

how-to for beginners from a beginner to run Debian Buster on Lime2 (Rev. K):

- Download latest repository of u-boot (https://gitlab.denx.de/u-boot/u-boot)
- add line "CONFIG_GMAC_TX_DELAY=3" to configs/A20-OLinuXino-Lime2_defconfig
- Get tool-chain and "Device-tree Compiler" to compile u-boot (https://linux-sunxi.org/Mainline_U-Boot#Compile_U-Boot)
- Go to u-boot directory and build u-boot --> outcome = "u-boot-sunxi-with-spl.bin"
- copy the file on your SD-card: dd if=u-boot-sunxi-with-spl.bin of=/dev/sdX bs=1k seek=8

- format separate USB-device as ext4 (e.g.) and unzip "hd-media.tar.gz" on it. (https://ftp.halifax.rwth-aachen.de/debian/dists/stable/main/installer-armhf/current/images/hd-media/hd-media.tar.gz)
- Get matching "debian net-installation.ISO" (or complete CD) and copy *.ISO on the USB-device.
- insert SD-card and USB-drive and power the device. u-boot should automatically find the ISO-file and starts the Debian Buster installer.

Sources:
https://linux-sunxi.org/Mainline_U-Boot#Compile_U-Boot
https://linux-sunxi.org/Bootable_SD_card#Bootloader
https://www.debian.org/releases/stable/armhf/ch05s01.en.html#boot-hd-media