⬢ DragonFlyBSD Kernel Audit
DF-3921 / trigger.sh
← back to finding ↓ download raw
#!/bin/sh
# DF-3921 - hptmv hpt_async panic("Here") on AC_LOST_DEVICE.
#
# hpt_attach registers (entry.c:2070-2075):
#     ccb->ccb_h.func_code = XPT_SASYNC_CB;
#     ccb->csa.event_enable = AC_LOST_DEVICE;
#     ccb->csa.callback = hpt_async;
# and hpt_async's body is unconditionally `panic("Here")` (entry.c:2147).
#
# AC_LOST_DEVICE is broadcast by CAM whenever a previously-probed target is
# gone at (re)scan:  sys/bus/cam/cam_xpt.c:6221-6223 (probe inquiry failure)
# and cam_xpt.c:6382-6384 (device changed), and cam_periph.c:1764
# (periph invalidation).  On a RAID controller, a dead/removed member disk is
# an *expected* event - the next bus scan (boot rescan, camcontrol rescan, or
# CAM error recovery) then panics the whole machine.
#
# Requires: hptmv controller present with a disk that disappears.
#   physical : power-off / unplug one RR1820 disk, then rescan
#   operator : camcontrol rescan <hptmv-bus>   (root/operator)
# Expected : kernel panic "Here" at hpt_async.
#
# The audit guest has no hptmv hardware (see env.txt); nothing to run here.
echo "hardware-gated trigger: requires HighPoint RR1820 + disk removal + bus rescan"
echo "see VERDICT.md for the source-level trace"