Howdy,

I am trying to use the RockPro64 as an OpenBSD router. I installed OpenBSD to 
an SD Card using the instructions found here:

https://github.com/krjdev/rock64_openbsd/

I compiled U-Boot myself on Ubuntu 20.04 for the required u-boot file following 
the instructions from the linked repo.

I powered the RockPro64 using the barrel power adapter from Pine64 and I used a 
USB serial adapter connected to the GPIO pins and read the serial output via 
picocom. 

I installed OpenBSD to the SD Card following the OpenBSD installer defaults and 
getting the base files from mirror.vdms.com as listed on the mirrors list.

I booted OpenBSD without the NIC first to ensure I had a working installation. 
I then halted the OpenBSD and pulled the barrel power connector.

I installed the I350-T2 NIC (https://www.amazon.com/gp/product/B01N1XX11W) into 
the RockPro64's PCI-E slot and plugged in an ethernet cable to the bottom 
interface to see if OpenBSD would recognize and connect via DHCP.

I connected the barrel power adapter again and OpenBSD booted then crashed. I 
have attached the crash logs here and created this bug at the suggestion of the 
panic message.

I'm not well versed in kernel development/debugging but I'm happy to help. I 
don't know anything further regarding reproducing the problem, but it does seem 
to happen every time I boot with the card plugged in.

Regards,
Larry
ddb{0}> show bcstats
Current Buffer Cache status:
numbufs 0 busymapped 0, delwri 0
kvaslots 11819 avail kva slots 11819
bufpages 0, dmapages 0, dirtypages 0
pendingreads 0, pendingwrites 0
highflips 0, highflops 0, dmaflips 0
ddb{0}> show uvm
Current UVM status:
  pagesize=4096 (0x1000), pagemask=0xfff, pageshift=12
  945571 VM pages: 0 active, 0 inactive, 0 wired, 934874 free (0 zero)
  min  10% (25) anon, 10% (25) vnode, 5% (12) vtext
  freemin=0, free-target=0, inactive-target=0, wired-max=0
  faults=1, traps=0, intrs=0, ctxswitch=0 fpuswitch=0
  softint=0, syscalls=0, kmapent=16
  fault counts:
    noram=0, noanon=0, noamap=0, pgwait=0, pgrele=0
    ok relocks(total)=0(0), anget(retries)=0(0), amapcopy=0
    neighbor anon/obj pg=0/0, gets(lock/unlock)=0/0
    cases: anon=0, anoncow=0, obj=0, prcopy=0, przero=0
  daemon and swap counts:
    woke=0, revs=0, scans=0, obscans=0, anscans=0
    busy=0, freed=0, reactivate=0, deactivate=0
    pageouts=0, pending=0, nswget=0
    nswapdev=0
    swpages=0, swpginuse=0, swpgonly=0 paging=0
  kernel pointers:
    objs(kern)=0xffffff8000cc1318
ddb{0}> ps
   PID     TID   PPID    UID  S       FLAGS  WAIT          COMMAND
*    0       0     -1      0  7     0x10200                swapper
ddb{0}> trace
db_enter() at panic+0x14c
panic() at handle_el1h_sync+0x6c
handle_el1h_sync() at pci_probe_device+0x6c
pci_probe_device() at pci_enumerate_bus+0x11c
pci_enumerate_bus() at pciattach+0xe8
pciattach() at config_attach+0x220
config_attach() at ppbattach+0x644
ppbattach() at config_attach+0x220
config_attach() at pci_probe_device+0x3f0
pci_probe_device() at pci_enumerate_bus+0x11c
pci_enumerate_bus() at config_attach+0x220
config_attach() at rkpcie_attach+0x6ec
rkpcie_attach() at config_attach+0x220
config_attach() at mainbus_attach_node+0x2c4
mainbus_attach_node() at mainbus_attach+0x298
mainbus_attach() at config_attach+0x220
config_attach() at cpu_configure+0x2c
cpu_configure() at main+0x308
main() at $x.2+0x70
U-Boot TPL 2020.10-rc4-g3dd52dd6 (Sep 13 2020 - 23:25:34)
Channel 0: LPDDR4, 50MHz
BW=32 Col=10 Bk=8 CS0 Row=16/15 CS=1 Die BW=16 Size=2048MB
Channel 1: LPDDR4, 50MHz
BW=32 Col=10 Bk=8 CS0 Row=16/15 CS=1 Die BW=16 Size=2048MB
256B stride
lpddr4_set_rate: change freq to 400000000 mhz 0, 1
lpddr4_set_rate: change freq to 800000000 mhz 1, 0
Trying to boot from BOOTROM
Returning to boot ROM...

U-Boot SPL 2020.10-rc4-g3dd52dd6 (Sep 13 2020 - 23:25:34 +0000)
Trying to boot from MMC1


U-Boot 2020.10-rc4-g3dd52dd6 (Sep 13 2020 - 23:25:34 +0000)

SoC: Rockchip rk3399
Reset cause: POR
Model: Pine64 RockPro64 v2.1
DRAM:  3.9 GiB
PMIC:  RK808 
MMC:   mmc@fe310000: 2, mmc@fe320000: 1, sdhci@fe330000: 0
Loading Environment from SPIFlash... Invalid bus 0 (err=-19)
*** Warning - spi_flash_probe_bus_cs() failed, using default environment

In:    serial
Out:   serial
Err:   serial
Model: Pine64 RockPro64 v2.1
Net:   eth0: ethernet@fe300000
Hit any key to stop autoboot:  0 
Card did not respond to voltage select!
switch to partitions #0, OK
mmc1 is current device
Scanning mmc 1:1...
Found EFI removable media binary efi/boot/bootaa64.efi
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
Card did not respond to voltage select!
Scanning disk [email protected]...
Disk [email protected] not ready
Scanning disk [email protected]...
** Unrecognized filesystem type **
Card did not respond to voltage select!
Scanning disk [email protected]...
Disk [email protected] not ready
Found 3 disks
No EFI system partition
BootOrder not defined
EFI boot manager: Cannot load any image
169176 bytes read in 14 ms (11.5 MiB/s)
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
Booting /efi\boot\bootaa64.efi
disks: sd0*
>> OpenBSD/arm64 BOOTAA64 0.22
boot> 
booting sd0a:/bsd: 7769872+1501120+542832+849136 
[513651+109+966984+545707]=0xd42d00
type 0x2 pa 0x200000 va 0x200000 pages 0x4000 attr 0x8
type 0x7 pa 0x4200000 va 0x4200000 pages 0x3eed attr 0x8
type 0x9 pa 0x80ed000 va 0x80ed000 pages 0x26 attr 0x8
type 0x7 pa 0x8113000 va 0x8113000 pages 0xe8141 attr 0x8
type 0x2 pa 0xf0254000 va 0xf0254000 pages 0xb8b attr 0x8
type 0x4 pa 0xf0ddf000 va 0xf0ddf000 pages 0x1 attr 0x8
type 0x2 pa 0xf0de0000 va 0xf0de0000 pages 0x3 attr 0x8
type 0x7 pa 0xf0de3000 va 0xf0de3000 pages 0x1 attr 0x8
type 0x2 pa 0xf0de4000 va 0xf0de4000 pages 0x100 attr 0x8
type 0x1 pa 0xf0ee4000 va 0xf0ee4000 pages 0x2a attr 0x8
type 0x0 pa 0xf0f0e000 va 0xf0f0e000 pages 0x7 attr 0x8
type 0x4 pa 0xf0f15000 va 0xf0f15000 pages 0x1 attr 0x8
type 0x6 pa 0xf0f16000 va 0x78c924000 pages 0x1 attr 0x8000000000000008
type 0x4 pa 0xf0f17000 va 0xf0f17000 pages 0x2 attr 0x8
type 0x0 pa 0xf0f19000 va 0xf0f19000 pages 0x1 attr 0x8
type 0x6 pa 0xf0f1a000 va 0x78c928000 pages 0x3 attr 0x8000000000000008
type 0x4 pa 0xf0f1d000 va 0xf0f1d000 pages 0x1 attr 0x8
type 0x6 pa 0xf0f1e000 va 0x78c92c000 pages 0x4 attr 0x8000000000000008
type 0x0 pa 0xf0f22000 va 0xf0f22000 pages 0x1 attr 0x8
type 0x4 pa 0xf0f23000 va 0xf0f23000 pages 0x1 attr 0x8
type 0x0 pa 0xf0f24000 va 0xf0f24000 pages 0x1 attr 0x8
type 0x4 pa 0xf0f25000 va 0xf0f25000 pages 0x2 attr 0x8
type 0x0 pa 0xf0f27000 va 0xf0f27000 pages 0x1 attr 0x8
type 0x4 pa 0xf0f28000 va 0xf0f28000 pages 0x2 attr 0x8
type 0x2 pa 0xf0f2a000 va 0xf0f2a000 pages 0x3016 attr 0x8
type 0x5 pa 0xf3f40000 va 0x78f94e000 pages 0x10 attr 0x8000000000000008
type 0x2 pa 0xf3f50000 va 0xf3f50000 pages 0x40b0 attr 0x8
[ using 2027424 bytes of bsd ELF symbol table ]
Copyright (c) 1982, 1986, 1989, 1991, 1993
        The Regents of the University of California.  All rights reserved.
Copyright (c) 1995-2020 OpenBSD. All rights reserved.  https://www.OpenBSD.org

OpenBSD 6.7 (GENERIC.MP) #6: Thu Sep  3 13:33:49 MDT 2020
    
[email protected]:/usr/src/sys/arch/arm64/compile/GENERIC.MP
real mem  = 4026720256 (3840MB)
avail mem = 3830366208 (3652MB)
mainbus0 at root: Pine64 RockPro64 v2.1
cpu0 at mainbus0 mpidr 0: ARM Cortex-A53 r0p4
cpu0: 32KB 64b/line 2-way L1 VIPT I-cache, 32KB 64b/line 4-way L1 D-cache
cpu0: 512KB 64b/line 16-way L2 cache
efi0 at mainbus0: UEFI 2.8
efi0: Das U-Boot rev 0x20201000
apm0 at mainbus0
psci0 at mainbus0: PSCI 1.1, SMCCC 1.2
agintc0 at mainbus0 sec shift 3:3 nirq 288 nredist 6 ipi: 0, 1: 
"interrupt-controller"
agintcmsi0 at agintc0
syscon0 at mainbus0: "qos"
syscon1 at mainbus0: "qos"
syscon2 at mainbus0: "qos"
syscon3 at mainbus0: "qos"
syscon4 at mainbus0: "qos"
syscon5 at mainbus0: "qos"
syscon6 at mainbus0: "qos"
syscon7 at mainbus0: "qos"
syscon8 at mainbus0: "qos"
syscon9 at mainbus0: "qos"
syscon10 at mainbus0: "qos"
syscon11 at mainbus0: "qos"
syscon12 at mainbus0: "qos"
syscon13 at mainbus0: "qos"
syscon14 at mainbus0: "qos"
syscon15 at mainbus0: "qos"
syscon16 at mainbus0: "qos"
syscon17 at mainbus0: "qos"
syscon18 at mainbus0: "qos"
syscon19 at mainbus0: "qos"
syscon20 at mainbus0: "qos"
syscon21 at mainbus0: "qos"
syscon22 at mainbus0: "qos"
syscon23 at mainbus0: "qos"
syscon24 at mainbus0: "qos"
syscon25 at mainbus0: "power-management"
"power-controller" at syscon25 not configured
syscon26 at mainbus0: "syscon"
"io-domains" at syscon26 not configured
rkclock0 at mainbus0
rkclock1 at mainbus0
syscon27 at mainbus0: "syscon"
"io-domains" at syscon27 not configured
"usb2-phy" at syscon27 not configured
"usb2-phy" at syscon27 not configured
rkemmcphy0 at syscon27
"pcie-phy" at syscon27 not configured
rkpinctrl0 at mainbus0: "pinctrl"
rkgpio0 at rkpinctrl0
rkgpio1 at rkpinctrl0
rkgpio2 at rkpinctrl0
rkgpio3 at rkpinctrl0
rkgpio4 at rkpinctrl0
pwmreg0 at mainbus0
syscon28 at mainbus0: "syscon"
syscon29 at mainbus0: "syscon"
"fit-images" at mainbus0 not configured
rkdrm0 at mainbus0
drm0 at rkdrm0
"pmu_a53" at mainbus0 not configured
"pmu_a72" at mainbus0 not configured
agtimer0 at mainbus0: tick rate 24000 KHz
"xin24m" at mainbus0 not configured
simplebus0 at mainbus0: "bus"
"dma-controller" at simplebus0 not configured
"dma-controller" at simplebus0 not configured
rkpcie0 at mainbus0
pci0 at rkpcie0
ppb0 at pci0 dev 0 function 0 "Rockchip RK3399 Root Complex" rev 0x00: msi
pci1 at ppb0 bus 1
panic: uvm_fault failed: ffffff800049d2d4 esr 96000210 far ffffff805040000c
Stopped at      panic+0x150:        TID    PID    UID     PRFLAGS     PFLAGS  C
PU  COMMAND
*     0      0      0     0x10000      0x200    0K swapper
db_enter() at panic+0x14c
panic() at handle_el1h_sync+0x6c
handle_el1h_sync() at pci_probe_device+0x6c
pci_probe_device() at pci_enumerate_bus+0x11c
pci_enumerate_bus() at pciattach+0xe8
pciattach() at config_attach+0x220
config_attach() at ppbattach+0x644
https://www.openbsd.org/ddb.html describes the minimum info required in bug
reports.  Insufficient info makes it difficult to find and fix bugs.

Reply via email to