Re: following -current on rpi4 with zfs-on-root

From: Warner Losh <imp_at_bsdimp.com>
Date: Sat, 24 Sep 2022 02:31:56 UTC
On Fri, Sep 23, 2022 at 8:30 PM Mark Millard <marklmi@yahoo.com> wrote:

> On 2022-Sep-23, at 16:32, void <void@f-m.fm> wrote:
>
> > On Tue, Sep 20, 2022 at 02:36:02PM -0600, Warner Losh wrote:
> >>> >
> >>> >> For EFI, there are many choices. The default installation places
> >>> >> loader.efi into the ESP in EFI\FREEBSD\LOADER.EFI. The following
> >>> >> updates it (assuming the ESP is on p1, and isn't already mounted):
> >>> >> mount -t msdos /dev/ada0p1 /boot/efi
> >>> >> cp /boot/efi/loader.efi /boot/efi/efi/freebsd
>
> I expect that should reference ( unsure for EFI vs. efi ):
>
> cp /boot/loader.efi /boot/efi/EFI/freebsd/
>

Yes.


> The point being to copy from ZFS/UFS to the ESP
> for environments that use EFI\FREEBSD\LOADER.EFI .
>
> -t msdos vs. -t msdosfs ?
>

Both are valid. There was an unwise attempt to convert everybody over to
using the latter, but too many people stubbornly used the old style that we
left it as an alias and deleted the warning... :)

Warner


> >>> >> If you have a non-standard setup, please see the EFI notes section.
> >
> > Hi Warner,
> >
> > On a freshly rebuilt system after make installworld (but before anything
> else),
> >
> > # mount | grep msdos
> >
> > /dev/da0p1 on /boot/efi (msdosfs, local)
> >
> > There is no loader.efi in /boot/efi on arm64.aarch64 for raspberry pi 4
>
> So far as I know /boot/efi/loader.efi is never the right
> path for ZFS, UFS, or the ESP under the msdosfs ( given
> mount -t msdos /dev/ada0p1 /boot/efi ). /dev/ada0p1 would
> contain an EFI directory that has more substructure.
>
> > bootaa64.efi is in /boot/efi/EFI/BOOT, so I followed Marek's
> instructions and copied loader_lua.efi to bootaa64.efi from
> > /usr/obj/usr/src/arm64.aarch64/stand/efi/loader_lua/
>
> After the install world, cp /boot/loader.efi /boot/efi/EFI/BOOT/
> should work as well. ( /boot/loader.efi having been updated in
> ZFS/UFS. )
>
>
> ===
> Mark Millard
> marklmi at yahoo.com
>
>
>