Re: u-boot debug, was: Re: U-boot on RPI3, sees disk but won't boot it

From: bob prohaska <fbsd_at_www.zefox.net>
Date: Tue, 04 Oct 2022 19:27:07 UTC
On Mon, Oct 03, 2022 at 06:24:07PM -0700, Mark Millard wrote:
> 
> 0x0583 vs. 0x0576 leaves open the possibility of a bad
> firmware revision in the part?
> 
There were hints of a firmware update from Sabrent long ago.
It found nothing to update. Yesterday I looked again and 
found a new date on the Downloads link but the same revision 
number on the download. It is, however, named 
"JMS583_FWUpdate_Utility..." which hints at some connection.  

Alas, the enclosure recognized as 0x0583 is not recognized at
all as supported. An enclosure recognized as 0x0577 is reported
"up to date". No help at all, since that one works worse.

> 
> So there are 4 EC-UASP enclosures overall? Could you be so lucky
> as to have (oldest EC-UASP's used on oldest RPi* family):
>

No. IIRC the first were tried  on Pi4's and seemed to work,
later I got more intending to use them on Pi2's in usb-only 
bootcode.bin boot mode. Happened to try first on the Pi3, 
and realized there was a problem. By then I had three bad
apples.

> Both 0x152d:0x1561 work with the RPi3B's
> and:
> 0x152d:0x0583 and 0x152d:0x0577 work with the RPi4B's?
> 

In the one test tried the 0x0583 worked on the Pi4. Haven't
tried the 0x0577, to my memory. That might be worth a go. 
 
> The team(s) that make EDK2 support the RPi3*'s and
> RPi4*'s publish releases when they update EDK2. I
> actively use a RPi4* EDK2 (UEFI/ACPI) on some 
> FreeBSD RPi4B's. (Other RPi4B's have the FreeBSD
> U-Boot context instead.) But my usage context is
> limited so what is supported via ACPI vs. not is
> not significant for me. I also have patches involved
> for this usage.
> 
> There is the FreeBSD port sysutils/edk2 with FLAVOR's
> for rpi3 and rpi4 (and more). These do not track the
> specific commits that those teams published based on,
> using more recent materials generally.
> 
> Currently, building sysutils/edk2 is broken. My
> submittal to make it build again has not been applied:
> 
> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=266404

EDK2 looks like a very long road. I'll take a look but not
hold my breath 8-) 

If there were some way to get u-boot started from microSD, 
tune it to find the disk and then save any tuning changes 
to uboot.env on the microSD it'd be a better match for my 
limited skills. I appreciate your objection that u-boot 
"still has to work" but the list of tunable environment 
variables is long and easy (relatively) to adjust. 

There's nothing at all wrong with a two-stage boot starting
with microSD and transferring to USB later on. I'm not a fan
of split configurations with root on microSD and /usr on USB,
but it worked acceptably when I used it.

Any pointers to novice-level instructions for either
u-boot or edk2 would be worth reading. I know of none.

Thanks for your continued patience!

bob prohaska