Date: Sat, 9 Jul 2022 21:23:42 -0700 From: Mark Millard <marklmi@yahoo.com> To: "freebsd-arm@freebsd.org" <arm@freebsd.org> Subject: Re: 13.1-RELEASE image fails to boot Rev 1.4 8 GiByte RPi4B (B0T vintage SOC) when dd'd to the example USB3 media then used to try to boot via USB3 port Message-ID: <0AB0761B-4E22-4181-A29D-F0260B6F8055@yahoo.com> In-Reply-To: <77F18A4B-6B89-478A-A0CF-306866014536@yahoo.com> References: <FEE03609-9D06-46FF-A9B0-A58B2622FF43@yahoo.com> <D5AEF496-4C52-4D7C-9DF3-1C6BACFDBAC1@yahoo.com> <77F18A4B-6B89-478A-A0CF-306866014536@yahoo.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On 2022-Jul-9, at 18:59, Mark Millard <marklmi@yahoo.com> wrote: > On 2022-Jul-5, at 15:45, Mark Millard <marklmi@yahoo.com> wrote: >=20 >> On 2022-Jul-5, at 14:17, Mark Millard <marklmi@yahoo.com> wrote: >>=20 >>> Summary for Rev 1.4 8 GiByte RPi4B (B0T vintage SOC) context: >>>=20 >>> A) One type of USB3 media (USB2 compatible) works for booting via = USB2-port. >>> B) The same media fails for USB3-port based boot attempts. >>> C) I boot the same type of media for main [so: 14] instead of = 13.1-RELEASE. >>> D) An alternate type of USB3 media (USB2 compatible) booted via USB3 = just >>> fine via 13.1-RELEASE. >>>=20 >>> The details . . . >>>=20 >>> I intended for for use in the Rev 1.4 8 GiByte RPi4B's >>> by first going onto USB3 media (of the same kind I >>> normally use on the RPi4B's with main and the like). >>> So, I tried:=20 >>>=20 >>> # dd if=3DFreeBSD-13.1-RELEASE-arm64-aarch64-RPI.img of=3D/dev/da0 \ >>> bs=3D1m conv=3Dsync status=3Dprogress >>>=20 >>> and then tried to boot the RPi4B via the media and it gets >>> the following (the kernel loads and runs but . . .): >>>=20 >>> . . . >>> Trying to mount root from ufs:/dev/ufs/rootfs [rw]... >>> uhub0: 5 ports with 4 removable, self powered >>> ugen0.2: <vendor 0x2109 USB2.0 Hub> at usbus0 >>> uhub1 on uhub0 >>> uhub1: <vendor 0x2109 USB2.0 Hub, class 9/0, rev 2.10/4.21, addr 1> = on usbus0 >>> Root mount waiting for: usbus0 >>> uhub1: 4 ports with 4 removable, self powered >>> Root mount waiting for: usbus0 >>> uhub_reattach_port: port 3 reset failed, error=3DUSB_ERR_TIMEOUT >>> uhub_reattach_port: device problem (USB_ERR_TIMEOUT), disabling port = 3 >>> mountroot: waiting for device /dev/ufs/rootfs... >>> Mounting from ufs:/dev/ufs/rootfs failed with error 19. >>>=20 >>> Loader variables: >>> vfs.root.mountfrom=3Dufs:/dev/ufs/rootfs >>> vfs.root.mountfrom.options=3Drw >>>=20 >>> Manual root filesystem specification: >>> <fstype>:<device> [options] >>> Mount <device> using filesystem <fstype> >>> and with the specified (optional) option list. >>>=20 >>> eg. ufs:/dev/da0s1a >>> zfs:zroot/ROOT/default >>> cd9660:/dev/cd0 ro >>> (which is equivalent to: mount -t cd9660 -o ro /dev/cd0 /) >>>=20 >>> ? List valid disk boot devices >>> . Yield 1 second (for background tasks) >>> <empty line> Abort manual input >>>=20 >>> mountroot>=20 >>>=20 >>> Plugging into the other USB3 port and attempting the >>> power on boot just changes the port numbers from 3 to 2 >>> in the sequence. >>>=20 >>> Plugging into a USB2 port does not have the problem and >>> it completes the boot and operates. (The media is USB3 >>> but USB2 compatible as well.) >>>=20 >>> Adding to /boot/loader.conf : >>>=20 >>> # First, 3 additions: >>> kern.cam.boot_delay=3D10000 >>> vfs.mountroot.timeout=3D10 >>> vfs.root_mount_always_wait=3D1 >>>=20 >>> and retrying via a USB3 port just results in: >>>=20 >>> . . . >>> Root mount waiting for: usbus0 CAM >>> uhub_reattach_port: port 3 reset failed, error=3DUSB_ERR_TIMEOUT >>> uhub_reattach_port: device problem (USB_ERR_TIMEOUT), disabling port = 3 >>> Root mount waiting for: CAM >>> Root mount waiting for: CAM >>> Root mount waiting for: CAM >>> Root mount waiting for: CAM >>> Root mount waiting for: CAM >>> Root mount waiting for: CAM >>> Mounting from ufs:/dev/ufs/rootfs failed with error 2; retrying for = 10 more seconds >>> Mounting from ufs:/dev/ufs/rootfs failed with error 2. >>>=20 >>> Loader variables: >>> vfs.root.mountfrom=3Dufs:/dev/ufs/rootfs >>> vfs.root.mountfrom.options=3Drw >>>=20 >>> Manual root filesystem specification: >>> <fstype>:<device> [options] >>> Mount <device> using filesystem <fstype> >>> and with the specified (optional) option list. >>>=20 >>> eg. ufs:/dev/da0s1a >>> zfs:zroot/ROOT/default >>> cd9660:/dev/cd0 ro >>> (which is equivalent to: mount -t cd9660 -o ro /dev/cd0 /) >>>=20 >>> ? List valid disk boot devices >>> . Yield 1 second (for background tasks) >>> <empty line> Abort manual input >>>=20 >>> mountroot>=20 >>>=20 >>> So: same problem. >>>=20 >>> For reference, from the media being plugged into a different >>> aarch64 FeeBSD machine running main: >>>=20 >>> usb_msc_auto_quirk: UQ_MSC_NO_GETMAXLUN set for USB mass storage = device Samsung PSSD T7 Touch (0x04e8:0x4001) >>> ugen1.5: <Samsung PSSD T7 Touch> at usbus1 >>> umass0 on uhub4 >>> umass0: <Samsung PSSD T7 Touch, class 0/0, rev 3.20/1.00, addr 9> on = usbus1 >>> umass0: SCSI over Bulk-Only; quirks =3D 0x0100 >>> umass0:6:0: Attached to scbus6 >>> da0 at umass-sim0 bus 0 scbus6 target 0 lun 0 >>> da0: <Samsung PSSD T7 Touch 0> Fixed Direct Access SPC-4 SCSI device >>> da0: Serial Number REDACTED >>> da0: 400.000MB/s transfers >>> da0: 953869MB (1953525168 512 byte sectors) >>> da0: quirks=3D0x2<NO_6_BYTE> >>>=20 >>> The RPi4B is of a vintage that has the "3 GiByte DMA" issue >>> present, not that it would be likely to be contributing here. >>>=20 >>>=20 >>> So I then tried the sequence using a different type of USB3 >>> media (also USB2 compatible), placed in a USB3 port to boot: >>>=20 >>> usb_msc_auto_quirk: UQ_MSC_NO_GETMAXLUN set for USB mass storage = device OWC Envoy Pro mini (0x1e91:0xa2a5) >>> ugen1.5: <OWC Envoy Pro mini> at usbus1 >>> umass0 on uhub4 >>> umass0: <OWC Envoy Pro mini, class 0/0, rev 3.00/1.00, addr 11> on = usbus1 >>> umass0: SCSI over Bulk-Only; quirks =3D 0x0100 >>> umass0:6:0: Attached to scbus6 >>> da0 at umass-sim0 bus 0 scbus6 target 0 lun 0 >>> da0: <OWC Envoy Pro mini 0> Fixed Direct Access SPC-4 SCSI device >>> da0: Serial Number REDACTED >>> da0: 400.000MB/s transfers >>> da0: 228936MB (468862128 512 byte sectors) >>> da0: quirks=3D0x2<NO_6_BYTE> >>>=20 >>> For this media, the sequence worked and booted successfully. >>>=20 >>>=20 >>> So the issue is somehow specific to some USB3 media=20 >>> used in the USB3 ports but not to others. "reset failed, >>> error=3DUSB_ERR_TIMEOUT" may need more time or better >>> recovery if a wider range of boot devices are to be >>> supported. May be the T7 Touch needs more than the >>> standard amount of time to reset as a USB3 device or >>> some such. (I've no clue about the details.) >>=20 >> I substituted a 13-STABLE kernel.txz expansion and got the >> same result using that kernel. (There are not .img files >> for this currently.) >=20 > I took a different path of setting up a stable/13 based > media, based on my own build context but upgrading a > 13.1-RELEASE starting point. This stable/13 variant boots > the RPi4B's just fine via the USB3 media that 13.1-RELEASE > failed to boot with. I'm not sure what the differences > that matter are. >=20 Well, the kernel.txz was based on: Thu, 30 Jun 2022 =E2=80=A2 git: 70fd40edb869 - stable/13 - debugnet: Fix an error = handling bug in the DDB command tokenizer Mark Johnston via: Fri, 01 Jul 2022 =E2=80=A2 New FreeBSD snapshots available: stable/13 (20220701 = 70fd40edb86) Glen Barber while my build was based on: stable/13-n251684-815db559eccc-dirty (815db559eccc is from Wed, 06 Jul 2022) Between those are: Fri, 01 Jul 2022 =E2=80=A2 git: 39cd7aa134df - stable/13 - USB: add quirks to = XHCI Bjoern A. Zeeb =E2=80=A2 git: 66754c01ff95 - stable/13 - XHCI: clear warm and = port reset Bjoern A. Zeeb and that last mentions port reset handling explicitly. It is, at least, suggestive. > For reference for the working stable/13 context and > other content involved: >=20 > # strings -a /boot/efi/start4.elf | grep VC_BUILD_ID_=20 > VC_BUILD_ID_USER: dom > VC_BUILD_ID_TIME: 12:10:40 > VC_BUILD_ID_VARIANT: start > VC_BUILD_ID_TIME: Feb 25 2021 > VC_BUILD_ID_BRANCH: bcm2711_2 > VC_BUILD_ID_HOSTNAME: buildbot > VC_BUILD_ID_PLATFORM: raspberrypi_linux > VC_BUILD_ID_VERSION: 564e5f9b852b23a330b1764bcf0b2d022a20afd0 (clean) >=20 > (/boot/efi/armstub8-gic.bin does not have very useful > version-string information.) >=20 > # strings -a /boot/efi/u-boot.bin | grep 'U-Boot 20' > U-Boot 2021.07 (May 12 2022 - 07:00:33 +0000) >=20 > Note: To my knowledge, the RPi* firmware, armstub8-gic.bin > file, and u-boot.bin file above are all as they were for > 13.1-RELEASE's image, other that for 13.1-RELEASE I had > also tried adding /boot/efi/timeout and I've left that > in place since then and I've added my usual > /boot/efi/config.txt material (that had also not made a > difference for 13.1-RELEASE). >=20 > (/boot/efi/EFI/BOOT/bootaa64.efi and > /boot/efi/EFI/freebsd/loader.efi do not have very useful > version-string information.) >=20 > # uname -apKU # manually line split > FreeBSD 13S-ufs 13.1-STABLE FreeBSD 13.1-STABLE #40 > stable/13-n251684-815db559eccc-dirty: Sat Jul 9 14:02:23 PDT 2022 > = root@CA72_16Gp_ZFS:/usr/obj/BUILDs/13S-CA72-nodbg-clang/usr/13S-src/arm64.= aarch64/sys/GENERIC-NODBG-CA72 > arm64 aarch64 1301505 1301505 >=20 >=20 > Unfortunately, it has been some time since a >=20 > FreeBSD-13.1-STABLE-arm64-aarch64-RPI-*.img >=20 > (a snapshot) has managed to build and be distributed. > I'm not sure what the result would be like for such at > this point. >=20 > Once such is available, I may do an experiment based on > just a stable/13 snapshot. >=20 >> But using: >>=20 >> = FreeBSD-14.0-CURRENT-arm64-aarch64-RPI-20220701-9aa02d5120a-256480.img >>=20 >> does not have the problem. >=20 =3D=3D=3D Mark Millard marklmi at yahoo.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?0AB0761B-4E22-4181-A29D-F0260B6F8055>