Page MenuHomeFreeBSD

vtblk: secondary fix for dumping
ClosedPublic

Authored by mhorne on Jan 9 2023, 5:24 PM.
Tags
None
Referenced Files
Unknown Object (File)
Nov 16 2024, 2:32 PM
Unknown Object (File)
Nov 16 2024, 1:49 PM
Unknown Object (File)
Nov 14 2024, 1:23 PM
Unknown Object (File)
Nov 14 2024, 3:14 AM
Unknown Object (File)
Nov 13 2024, 11:50 AM
Unknown Object (File)
Nov 10 2024, 9:36 AM
Unknown Object (File)
Nov 8 2024, 10:19 PM
Unknown Object (File)
Nov 8 2024, 6:40 PM
Subscribers

Details

Summary

Don't call bus_dmamap_sync() with a NULL map. The x86 implementation
tolerates this but others do not.

Test Plan

Sample backtrace from an arm64 VM without this change:

debug.kdb.enter: 0KDB: enter: sysctl debug.kdb.enter
[ thread pid 1003 tid 100063 ]
Stopped at      kdb_sysctl_enter+0x98:  undefined       f900827f
db> dump
Dumping 110 out of 488 MB:KDB: reentering
KDB: stack backtrace:
db_trace_self() at db_trace_self
db_trace_self_wrapper() at db_trace_self_wrapper+0x30
kdb_reenter() at kdb_reenter+0x44
handle_el1h_sync() at handle_el1h_sync+0x10
--- exception, esr 0x96000004
bounce_bus_dmamap_sync() at bounce_bus_dmamap_sync+0x3c
vtblk_request_execute_cb() at vtblk_request_execute_cb+0x1f4
vtblk_poll_request() at vtblk_poll_request+0x9c
vtblk_dump() at vtblk_dump+0xd0
_dump_append() at _dump_append+0x10c
blk_write() at blk_write+0x134
cpu_minidumpsys() at cpu_minidumpsys+0x670
dumpsys_generic() at dumpsys_generic+0x64
doadump() at doadump+0x74
db_dump() at db_dump+0x30
db_command() at db_command+0x2e4
db_command_loop() at db_command_loop+0x54
db_trap() at db_trap+0xf8
kdb_trap() at kdb_trap+0x28c
handle_el1h_sync() at handle_el1h_sync+0x10
--- exception, esr 0xf2000000
kdb_sysctl_enter() at kdb_sysctl_enter+0x98
sysctl_root_handler_locked() at sysctl_root_handler_locked+0xe0
sysctl_root() at sysctl_root+0x1ac
userland_sysctl() at userland_sysctl+0x144
sys___sysctl() at sys___sysctl+0x68
do_el0_sync() at do_el0_sync+0x54c
handle_el0_sync() at handle_el0_sync+0x40
--- exception, esr 0x56000000

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

mhorne requested review of this revision.Jan 9 2023, 5:24 PM
This revision was not accepted when it landed; it landed in state Needs Review.Jan 23 2023, 7:21 PM
This revision was automatically updated to reflect the committed changes.