
On Mon, Feb 05, 2018 at 11:31:42AM +0100, Mark Kettenis wrote:
Date: Mon, 5 Feb 2018 21:06:59 +1100 From: Jonathan Gray jsg@jsg.id.au
booting sd0a:/bsd: open sd0a:/bsd: Device not configured failed(6). will try /bsd
How do you find out that it's sd0a instead of sd1a?
The loaded image protocol I believe.
Actually the OpenBSD bootloader currently only supports loading the bsd kernel from the same device as the bootloader. It will always call that device sd0. It invokes the device path protocol on the loaded image handle and then matches that path to a device that supports the block io protocol.
Perhaps the problem is elsewhere as U-Boot master also broke vexpress_ca15_tc2 and mx6cuboxi targets:
$ qemu-system-arm -m 1024 -nographic -M vexpress-a15 -dtb /usr/local/share/dtb/arm/vexpress-v2p-ca15-tc1.dtb -kernel /usr/local/share/u-boot/vexpress_ca15_tc2/u-boot -sd /tmp/miniroot-am335x-62.fs WARNING: Image format was not specified for '/tmp/miniroot-am335x-62.fs' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions.
U-Boot 2018.01 (Feb 06 2018 - 23:26:43 -0700)
DRAM: 1 GiB WARNING: Caches not enabled Flash: 128 MiB MMC: MMC: 0 *** Warning - bad CRC, using default environment
In: serial Out: serial Err: serial Net: smc911x-0 Hit any key to stop autoboot: 0 => load mmc 0:1 ${ramdisk_addr} fdt.dtb reading fdt.dtb 13384 bytes read in 2153 ms (5.9 KiB/s) => load mmc 0:1 ${loadaddr} efi/boot/bootarm.efi reading efi/boot/bootarm.efi 76528 bytes read in 51 ms (1.4 MiB/s) => bootefi ${loadaddr} ${ramdisk_addr} ## Starting EFI application at a0008000 ... Scanning disks on mmc... MMC Device 1 not found MMC Device 2 not found MMC Device 3 not found Found 3 disks WARNING: Invalid device tree, expect boot to fail
OpenBSD/armv7 BOOTARM 1.0
boot> cannot open sd0a:/etc/random.seed: No such file or directory booting sd0a:/bsd: 2648671+8030940+445060 [168774+90+179792+153619]=0xb1812c
$ qemu-system-arm -m 1024 -nographic -M vexpress-a15 -dtb /usr/local/share/dtb/arm/vexpress-v2p-ca15-tc1.dtb -kernel vexpress_ca15_tc2/u-boot -sd /tmp/miniroot-am335x-62.fs WARNING: Image format was not specified for '/tmp/miniroot-am335x-62.fs' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions.
U-Boot 2018.03-rc1-00185-g1e19c70639 (Feb 08 2018 - 18:24:11 +1300)
DRAM: 1 GiB WARNING: Caches not enabled Flash: 128 MiB MMC: MMC: 0 *** Warning - bad CRC, using default environment
In: serial Out: serial Err: serial Net: smc911x-0 Hit any key to stop autoboot: 0 => load mmc 0:1 ${ramdisk_addr} fdt.dtb unable to select a mode mmc_init: -524, time 22 unable to select a mode mmc_init: -524, time 21 ** Bad device mmc 0 ** => load mmc 0:1 ${loadaddr} efi/boot/bootarm.efi unable to select a mode mmc_init: -524, time 21 unable to select a mode mmc_init: -524, time 21 ** Bad device mmc 0 ** => bootefi ${loadaddr} ${ramdisk_addr} ## Starting EFI application at a0008000 ... WARNING: using memory device/image path, this may confuse some payloads! Scanning disks on mmc... unable to select a mode mmc_init: -524, time 21 MMC Device 1 not found MMC Device 2 not found MMC Device 3 not found Found 0 disks WARNING: Invalid device tree, expect boot to fail efi_load_pe: Invalid DOS Signature ## Application terminated, r = 2147483646
U-Boot SPL 2018.01 (Feb 06 2018 - 23:13:29) Trying to boot from MMC1
U-Boot 2018.01 (Feb 06 2018 - 23:13:29 -0700)
CPU: Freescale i.MX6Q rev1.5 996 MHz (running at 792 MHz) CPU: Extended Commercial temperature grade (-20C to 105C) at 54C Reset cause: WDOG Board: MX6 Cubox-i DRAM: 2 GiB MMC: FSL_SDHC: 0 No panel detected: default to HDMI Display: HDMI (1024x768) In: serial Out: serial Err: serial Net: FEC Hit any key to stop autoboot: 0 switch to partitions #0, OK mmc0 is current device Scanning mmc 0:1... reading /imx6q-cubox-i.dtb 37503 bytes read in 19 ms (1.9 MiB/s) Found EFI removable media binary efi/boot/bootarm.efi Scanning disks on usb... Scanning disks on mmc... MMC Device 1 not found MMC Device 2 not found MMC Device 3 not found Scanning disks on sata... Found 8 disks reading efi/boot/bootarm.efi 76528 bytes read in 32 ms (2.3 MiB/s) ## Starting EFI application at 12000000 ...
OpenBSD/armv7 BOOTARM 1.0
boot> booting sd0a:/bsd: 4531856+203028+560156[277405+90+281904+244582]=0x5d6b88
U-Boot SPL 2018.03-rc1-00185-g1e19c70639 (Feb 08 2018 - 17:54:19 +1300) Trying to boot from MMC1
U-Boot 2018.03-rc1-00185-g1e19c70639 (Feb 08 2018 - 17:54:19 +1300)
CPU: Freescale i.MX6Q rev1.5 996 MHz (running at 792 MHz) CPU: Extended Commercial temperature grade (-20C to 105C) at 53C Reset cause: WDOG Board: MX6 Cubox-i DRAM: 2 GiB MMC: FSL_SDHC: 0 Loading Environment from MMC... OK No panel detected: default to HDMI Display: HDMI (1024x768) In: serial Out: serial Err: serial Net: FEC Hit any key to stop autoboot: 0 switch to partitions #0, OK mmc0 is current device Scanning mmc 0:1... 37503 bytes read in 17 ms (2.1 MiB/s) Found EFI removable media binary efi/boot/bootarm.efi Scanning disks on usb... 76528 bytes read in 30 ms (2.4 MiB/s) ## Starting EFI application at 12000000 ... BS->LocateHandle() returns -2147483634 undefined instruction pc : [<8e560348>] lr : [<8e56444c>] reloc pc : [<15de4348>] lr : [<15de844c>] sp : 8f57af10 ip : 8ffc2474 fp : 8f57af1c r10: 0000b000 r9 : 8f57bee0 r8 : 0000000b r7 : 8ffa1a9d r6 : 8ffa16ad r5 : 8e56f0d0 r4 : 8e56e88a r3 : 8e56dac8 r2 : 00000001 r1 : 00000000 r0 : 00000000 Flags: nZCv IRQs off FIQs off Mode SVC_32 Resetting CPU ...
resetting ...