⬢ DragonFlyBSD Kernel Audit
DF-4923 / check_hardware.sh
← back to finding ↓ download raw
#!/bin/sh
# DF-4923 evidence: prove the trigger precondition (ThunderLAN hardware) is absent.
# Run as root on the DragonFly guest.
echo "TLPHY-DF-4923: uname: $(uname -a)"
echo "TLPHY-DF-4923: kern.ident: $(sysctl -n kern.ident)"
n=$(pciconf -l 2>/dev/null | grep -cE "vendor=0x100c|vendor=0x168c")
total=$(pciconf -l 2>/dev/null | wc -l | tr -d ' ')
echo "TLPHY-DF-4923: pci devices: $total, TI(0x100c)/Atheros(0x168c) matches: $n"
if [ "$n" = "0" ]; then
	echo "TLPHY-DF-4923: no ThunderLAN (vendor 0x100c) or Atheros (0x168c) PCI device present"
	echo "TLPHY-DF-4923: tl/miibus compiled into X86_64_GENERIC but no device to attach -> path unreachable"
	echo "TLPHY-DF-4923: finding NOT reproduced (hardware absent)"
	exit 3
fi
echo "TLPHY-DF-4923: hardware present - manual trigger analysis required"
exit 0