Re: BeagleBone uboot: BeagleBone Green Gateway not defined in uboot?

Johan Henselmans <[email protected]>
Newsgroups gmane.os.freebsd.devel.arm
Message-ID <[email protected]>
I made some comments in between on both mails.

> On 24 Oct 2022, at 23:30, Mark Millard <[email protected]> wrote:
> 
> On 2022-Oct-24, at 14:05, Mark Millard <[email protected]> wrote:
> 
>> On 2022-Oct-24, at 12:35, Johan Henselmans <[email protected]> wrote:
>> 
>>> I have tried to boot a Beaglebone Green Gateway via the current GenericSD.img.xz at https://download.freebsd.org/ftp/releases/arm/armv7/ISO-IMAGES/13.0/FreeBSD-13.0-RELEASE-arm-armv7-GENERICSD.img.xz
>> 
>> You list 13.0-RELEASE 's image instead of 13.1-RELEASE 's image:
>> 


Sorry, my mistake, the one I downloaded was 13.1, I copied the wrong link. Sorry for the confusion.

>> http://ftp3.freebsd.org/pub/FreeBSD/releases/ISO-IMAGES/13.1/FreeBSD-13.1-RELEASE-arm-armv7-GENERICSD.img.xz
>> 
>> (I've no clue if it makes a difference.)
>> 
>>> The board booted, but it did not have anything functional in the sense of wland or ethernet.
>>> 
>>> So I installed (after putting the SD-card in a BeagleBone Green, which was able to find an ethernet port and a working internet connection) the beaglebone uboot:
>>> =====
>>> pkg install sysutils/u-boot-beaglebone
>>> =====
>> 
>> pkg install sysutils/u-boot-beaglebone
>> 
>> only puts things in the likes of:
>> 
>> /usr/local/share/u-boot/u-boot-beaglebone/
>> 
>> /usr/local/share/u-boot/u-boot-beaglebone/ probably ended up
>> with a README or some such file name for the content shown
>> below.
>> 
>> # more /usr/ports/sysutils/u-boot-beaglebone/pkg-descr
>> U-Boot loader for BeagleBone and BeagleBone Black.
>> 
>> To install this bootloader, copy the files MLO and bb-uboot.img to the FAT
>> partition on an SD card or the eMMC.  Normally this is partition 1, but
>> different partitions can be set with U-Boot environment variables.
>> 
>> This version is patched so that:
>> * API features are enabled.
>> * A boot.scr (U-Boot scripts ) that loads ubldr.bin and execute it is included
>> 
>> For information about running FreeBSD on BeagleBone or BeagleBone Black, see
>> https://wiki.freebsd.org/FreeBSD/arm/BeagleBone
>> 
>> 
>> 
>> You were not explicit. Did you do as described with MLO
>> and bb-uboot.img ?
>> 


Yes I did. Only thing I did not know how to do was where to put the boot.scr that the READMe mentions.

That is why I reran the script on a Beaglebone, hoping that would install the script. Mind you, I am not a
pkg specialist. I do not know how to find out how this script is created and where it is supposed to put.
I looked in /usr/port/sysutils/u-boot-master and /usr/port/sysutils/u-boot-beaglebone, but could not understand
where this boot.scr was supposed to go


>> 
>>> That resulted in the message that there was no device tree:
>>> =====
>>> Loading Environment from EXT4...
>>> ** Unable to use mmc 0:1 for loading the env **
>>> Board: BeagleBone Black
>>> <ethaddr> not set. Validating first E-fuse MAC
>>> BeagleBone Black:
>>> Model: SeeedStudio BeagleBone Green Gateway:
>>> BeagleBone: cape eeprom: i2c_probe: 0x54:
>>> BeagleBone: cape eeprom: i2c_probe: 0x55:
>>> BeagleBone: cape eeprom: i2c_probe: 0x56:
>>> BeagleBone: cape eeprom: i2c_probe: 0x57:
>>> Net:   eth0: MII MODE
>>> cpsw, usb_ether
>>> Press SPACE to abort autoboot in 0 seconds
>>> board_name=[A335BNLT] ...
>>> board_rev=[GG1A] ...
>>> switch to partitions #0, OK
>>> mmc0 is current device
>>> SD/MMC found on device 0
>>> switch to partitions #0, OK
>>> mmc0 is current device
>>> Scanning mmc 0:1...
>>> Found EFI removable media binary efi/boot/bootarm.efi
>>> libfdt fdt_check_header(): FDT_ERR_BADMAGIC
>>> 
>>> <snip>
>>> No valid device tree blob found!
>>> WARNING! Trying to fire up the kernel, but no device tree blob found!
>>> =====
>>> 
>>> 
>>> How can I add a  device tree blob for the BeagleBone Green Gateway?
>>> 
>> 
>> Note: I've no experience with any BeagleBone variant.
>> My comments are rather generic.
>> 
> 
> Hmm, I do not see am335x-bonegreen-gateway.dts in any
> of the source code trees I've got for releng/13.0 ,
> releng/13.1 , stable/13 , or main [so: 14] :
> 
> /usr/13_0R-src/sys/contrib/device-tree/src/arm/am335x-bone.dts
> /usr/13_0R-src/sys/contrib/device-tree/src/arm/am335x-boneblack-wireless.dts
> /usr/13_0R-src/sys/contrib/device-tree/src/arm/am335x-boneblack.dts
> /usr/13_0R-src/sys/contrib/device-tree/src/arm/am335x-boneblue.dts
> /usr/13_0R-src/sys/contrib/device-tree/src/arm/am335x-bonegreen-wireless.dts
> /usr/13_0R-src/sys/contrib/device-tree/src/arm/am335x-bonegreen.dts
> 
> /usr/13_1R-src/sys/contrib/device-tree/src/arm/am335x-bone.dts
> /usr/13_1R-src/sys/contrib/device-tree/src/arm/am335x-boneblack-wireless.dts
> /usr/13_1R-src/sys/contrib/device-tree/src/arm/am335x-boneblack.dts
> /usr/13_1R-src/sys/contrib/device-tree/src/arm/am335x-boneblue.dts
> /usr/13_1R-src/sys/contrib/device-tree/src/arm/am335x-bonegreen-wireless.dts
> /usr/13_1R-src/sys/contrib/device-tree/src/arm/am335x-bonegreen.dts
> 
> /usr/13S-src/sys/contrib/device-tree/src/arm/am335x-bone.dts
> /usr/13S-src/sys/contrib/device-tree/src/arm/am335x-boneblack-wireless.dts
> /usr/13S-src/sys/contrib/device-tree/src/arm/am335x-boneblack.dts
> /usr/13S-src/sys/contrib/device-tree/src/arm/am335x-boneblue.dts
> /usr/13S-src/sys/contrib/device-tree/src/arm/am335x-bonegreen-wireless.dts
> /usr/13S-src/sys/contrib/device-tree/src/arm/am335x-bonegreen.dts
> 
> /usr/main-src/sys/contrib/device-tree/src/arm/am335x-bone.dts
> /usr/main-src/sys/contrib/device-tree/src/arm/am335x-boneblack-wireless.dts
> /usr/main-src/sys/contrib/device-tree/src/arm/am335x-boneblack.dts
> /usr/main-src/sys/contrib/device-tree/src/arm/am335x-boneblue.dts
> /usr/main-src/sys/contrib/device-tree/src/arm/am335x-bonegreen-wireless.dts
> /usr/main-src/sys/contrib/device-tree/src/arm/am335x-bonegreen.dts
> 
> Looks like you would have to establish am335x-bonegreen-gateway.dtb
> another way as things are.
> 
> I also did not find am335x-bonegreen-gateway.dtb in:
> 
> https://github.com/torvalds/linux/tree/master/arch/arm/boot/dts/
> 
> so it would likely be some time before it shows up there for FreeBSD
> to later import.
> 
> ===
> Mark Millard
> marklmi at yahoo.com
> 
> 

It seems the Beaglebne stuf is located at https://github.com/beagleboard/BeagleBoard-DeviceTrees/

There is a am335x-bonegreen-gateway.dts available over there. I don’t know why that stuff is not in torvalds tree.
I know that the debian version is created from https://github.com/RobertCNelson/omap-image-builder

So my question would be then revolve around: how can I add that version to FreeBSD arm? Is there some procedure
documented somehwere how I should do this?


Kind Regards,
Johan Henselmans
signature.asc (application/pgp-signature, 195 B)
-----BEGIN PGP SIGNATURE-----

iF0EARECAB0WIQSodLt4EnpKN6iAlsNa7fo9b51glAUCY1ePWQAKCRBa7fo9b51g
lNoeAJ0Uoa5+mwRozFu660ni2vprm+etHwCePHIdeYG58iVUEWTo6/fzuqrf7vc=
=pFAV
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.