I send a fresh bug report since I have more accurate information.
When writing/reading on an USB external drive (with its own power
cable), when high i/o, the kernel crash.
Here are some relevant information to debug.
Please, let me know if I can give you anything else.
## How to reproduce the bug :
Copy a big file to an USB drive
## mount
/dev/sd0a on / type ffs (local)
/dev/sd0f on /usr type ffs (local, nodev)
/dev/sd0g on /usr/X11R6 type ffs (local, nodev)
/dev/sd0k on /usr/local type ffs (local, nodev, wxallowed)
/dev/sd0j on /usr/obj type ffs (local, nodev, nosuid)
/dev/sd0h on /usr/src type ffs (local, nodev, nosuid)
/dev/sd1a on /var type ffs (local, noatime, nodev, nosuid, softdep)
/dev/sd1d on /tmp type ffs (local, noatime, nodev, nosuid, softdep)
/dev/sd1e on /home type ffs (local, noatime, nodev, nosuid, softdep)
## Error message on console :
usb_insert_transfer: xfer=0xffffff800bba3b40 not free
usb_insert_transfer: xfer=0xffffff800bba3b40 not free
usb_insert_transfer: xfer=0xffffff800bba3b40 not free
/var: got error 5 while accessing filesystem
panic: softdep_deallocate_dependencies: unrecovered I/O error
Stopped at panic+0x154: TID PID 0 1 sha256
db_enter() at panic+0x150
panic() at brelse+0xc4
brelse() at sd_buf_done+0x10c
sd_buf_done() at scsi_done+0x34
scsi_done() at usb_transfer_complete+0x238
usb_transfer_complete() at xhci_event_dequeue+0x148
xhci_event_dequeue() xhci_softintr+0x34
https://www.openbsd.org/ddb.html describes the minimum info required in
bug
reports. Insufficient info makes it difficult to find and fix bugs.
## traceback and ddb
ddb{0}> show uvm
Current UVM status:
pagesize=4096 (0x1000), pagemask=0xfff, pageshift=12
988985 VM pages: 48865 active, 43893 inactive, 0 wired, 817424 free
(102179 zero)
min 10% (25) anon, 10% (25) vnode, 5% (12) vtext
freemin=32966, free-target=43954, inactive-target=43955,
wired-max=329661
faults=423995, traps=0total)=15880(15880), anget(retries)=174749(0),
amapcopy=134052
neighbor anon/obj pg=13091/127755,
gets(lock/unlock)=113066/15880
cases: anon=153490, anoncow=21259, obj=104525, prcopy=8541,
przero=136182
daemon and swap counts:
woke=2, rev swpages=145355, swpginuse=0, swpgonly=0 paging=0
kernel pointers:
objs(kern)=0xffffff8000aba428
ddb{0}> show bcstats
Current Buffer Cache status:
numbufs 7491 busymapped 24, delwri 86
kvaslots 6553 avail kva slots 6529
bufpages 31752, dmapages 31752, dirtypages 532
pendingreads 6, pendingwrites 17
highflips 0, highflops 0, dmaflips 0
ddb{0}> show panic
softdep_deallocate_dependencies: unrecovered I/O error
ddb{0}> trace
db_enter() at panic+0x150
panic() at brelse+0xc4
brelse() at sd_buf_done+0x10c
sd_buf_done() at scsi_done+0x34
scsi_done() at usb_transfer_complete+0x238
usb_transfer_complete() at xhci_event_dequeue+0x148
xhci_event_dequeue() at xhci_softintr+0x34
xhci_softintr() at softintr_biglock_wrap+0x28
softintr_bigloc softintr_dispatch+0xa0
softintr_dispatch() at arm_do_pending_intr+0xac
arm_do_pending_intr() at ampintc_irq_handler+0x188
ampintc_irq_handler() at handle_el1h_irq+0x6c
handle_el1h_irq() at sched_idle+0x264
sched_idle() at proc_trampoline+0x10
ddb{0}
db_enter() at panic+0x150
panic() at brelse+0xc4
brelse() at sd_buf_done+0x10c
sd_buf_done() at scsi_done+0x34
scsi_done() at usb_transfer_complete+0x238
usb_transfer_complete() at xhci_event_dequeue+0x148
xhci_event_dequeue() at xhci_softintr+0x34tr() at
softintr_biglock_wrap+0x28
softintr_biglock_wrap() at softintr_dispatch+0xa0
softintr_dispatch() at arm_do_pending_intr+0xac
arm_do_pending_intr() at ampintc_irq_handler+0x188
ampintc_irq_handler() at handle_el1h_irq+0x6c
handle_el1h_irq() at sched_idle+0x264
sched_idle() at proc_trampoline+0x10
ddb{0}>
db_enter() at panic+0x150
panic() at brelse+0xc4
brelse() at sd_buf_done+0x10c
sd_buf_done() at scsi_done+0x34
scsi_done() at usb_transfer_complete+0x238
usb_transfer_complete() at xhcix148
xhci_event_dequeue() at xhci_softintr+0x34
xhci_softintr() at softintr_biglock_wrap+0x28
softintr_biglock_wrap() at softintr_dispatch+0xa0
softintr_dispatch() at arm_do_pending_intr+0xac
arm_do_pending_intr() at ampintc_irq_handler+0x188
ampintc_irq_handler() at handle_el1h_irq+0x6c
handle_el1h_irq() at sched_idle+0x264
sched_idle() at proc_trampoline+0x10
## dmesg
OpenBSD 6.4-current (GENERIC.MP) #389: Sat Jan 19 00:50:34 MST 2019
[email protected]:/usr/src/sys/arch/arm64/compile/GENERIC.MP
real mem = 4213825536 (4018MB)
avail mem = 4050710528 (3863MB)
mainbus0 at root: Pine64 Rock64
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: 256KB 64b/line 16-way L2 cache
efi0 at mainbus0: UEFI 2.0.5
efi0: Das U-boot rev 0x0
psci0 at mainbus0: PSCI 1.0
syscon0 at mainbus0: "syscon"
"io-domains" at syscon0 not configured
"grf-gpio" at syscon0 not configured
"power-controller" at syscon0 not configured
"reboot-mode" at syscon0 not configured
rkclock0 at mainbus0
syscon1 at mainbus0: "syscon"
"usb2-phy" at syscon1 not configured
ampintc0 at mainbus0 nirq 160, ncpu 4 ipi: 0, 1: "interrupt-controller"
rkpinctrl0 at mainbus0: "pinctrl"
rkgpio0 at rkpinctrl0
rkgpio1 at rkpinctrl0
rkgpio2 at rkpinctrl0
rkgpio3 at rkpinctrl0
simplebus0 at mainbus0: "amba"
"dmac" at simplebus0 not configured
agtimer0 at mainbus0: tick rate 24000 KHz
com0 at mainbus0: ns16550, no working fifo
com0: console
rkiic0 at mainbus0
iic0 at rkiic0
rkpmic0 at iic0 addr 0x18: RK805
rktemp0 at mainbus0
dwmmc0 at mainbus0: 50 MHz base clock
sdmmc0 at dwmmc0: 4-bit, sd high-speed, mmc high-speed, dma
dwmmc1 at mainbus0: 50 MHz base clock
sdmmc1 at dwmmc1: 8-bit, mmc high-speed, dma
dwge0 at mainbus0
dwge0: address: d6:8f:58:d2:50:ce
rgephy0 at dwge0 phy 0: RTL8169S/8110S/8211 PHY, rev. 6
ehci0 at mainbus0
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 configuration 1 interface 0 "Generic EHCI root hub" rev
2.00/1.00 addr 1
ohci0 at mainbus0: version 1.0
rkdwusb0 at mainbus0: "usb"
xhci0 at rkdwusb0, xHCI 1.16
usb1 at xhci0: USB revision 3.0
uhub1 at usb1 configuration 1 interface 0 "Generic xHCI root hub" rev
3.00/1.00 addr 1
cpu1 at mainbus0 mpidr 1: ARM Cortex-A53 r0p4
cpu1: 32KB 64b/line 2-way L1 VIPT I-cache, 32KB 64b/line 4-way L1
D-cache
cpu1: 256KB 64b/line 16-way L2 cache
cpu2 at mainbus0 mpidr 2: ARM Cortex-A53 r0p4
cpu2: 32KB 64b/line 2-way L1 VIPT I-cache, 32KB 64b/line 4-way L1
D-cache
cpu2: 256KB 64b/line 16-way L2 cache
cpu3 at mainbus0 mpidr 3: ARM Cortex-A53 r0p4
cpu3: 32KB 64b/line 2-way L1 VIPT I-cache, 32KB 64b/line 4-way L1
D-cache
cpu3: 256KB 64b/line 16-way L2 cache
usb2 at ohci0: USB revision 1.0
uhub2 at usb2 configuration 1 interface 0 "Generic OHCI root hub" rev
1.00/1.00 addr 1
sdmmc1: can't enable card
scsibus0 at sdmmc0: 2 targets, initiator 0
sd0 at scsibus0 targ 1 lun 0: <SD/MMC, USD00, 0010> SCSI2 0/direct
removable
sd0: 15080MB, 512 bytes/sector, 30883840 sectors
umass0 at uhub0 port 1 configuration 1 interface 0 "Norelsys NS1068"
rev 2.10/1.00 addr 2
umass0: using SCSI over Bulk-Only
scsibus1 at umass0: 2 targets, initiator 0
sd1 at scsibus1 targ 1 lun 0: <ATA, Samsung SSD 850, 2B6Q> SCSI4
0/direct fixed serial.253710683456789ABCDE
sd1: 953869MB, 512 bytes/sector, 1953525168 sectors
vscsi0 at root
scsibus2 at vscsi0: 256 targets
softraid0 at root
scsibus3 at softraid0: 256 targets
bootfile: sd0a:/bsd
boot device: sd0
root on sd0a (09cbdf9d3427561f.a) swap on sd0b dump on sd0b
--
thuban