โฌข DragonFlyBSD Kernel Audit
DF-5617 / fix_build.log
โ† back to finding โ†“ download raw
DF-5617 fix build โ€” patched ig4.ko built in the guest from /usr/src
(snapshot with-src), X86_64_GENERIC kernel build env.

Two builds were performed (identical result; the second re-verified after
the guest was reset between them):

  root@dfbsd: cd /usr/src/sys/bus/smbus/ichiic
  root@dfbsd: patch < /root/fix.diff
      Hunk #1 succeeded at 648.
  root@dfbsd: SYSDIR=/usr/src/sys make \
      KERNBUILDDIR=/usr/obj/usr/src/sys/X86_64_GENERIC

  (rebuild tail โ€” full compile of ig4_acpi.c, ig4_pci.c, ig4_iic.c with
   the kernel CFLAGS, -Werror, -DKLD_MODULE;:)
  cc ... -Werror -DKLD_MODULE ... -c ig4_acpi.c
  cc ... -Werror -DKLD_MODULE ... -c ig4_pci.c
  cc ... -Werror -DKLD_MODULE ... -c ig4_iic.c
  cc -Wl,--build-id=sha1 -nostdlib -Wl,--hash-style=sysv -r -Wl,-d \
      -o ig4.ko ig4_acpi.o ig4_pci.o ig4_iic.o
  BUILD_RC=0
  -rw-r--r-- 1 root wheel 1000 34584 ig4.ko
  MD5 (ig4.ko) = 5ed19131c62596a9c1271a26071f6b1b

No warnings, no errors.  The resulting module carries the one-line
lwkt_serialize_exit(&sc->slz) on ig4_iic.c's bus_setup_intr error path;
loading it (instead of stock /boot/kernel/ig4.ko) and re-running the exact
DF-5617 scenario produced run-fixed.log: the serializer comes back
RELEASED (IS_SERIALIZED: 0), the ig4_acpi.c:134 unwinder replay returns 0,
no panic, guest stays up โ€” versus the baseline panic (run.log/panic.txt)
with the stock module on the same kernel.

(The earlier fix-validation A/B on the first build produced run-fixed.log;
the rebuild above re-confirmed the patched module builds cleanly after the
guest was reset to the with-src snapshot. /usr/src was restored to
unpatched by the final vm.sh reset with-src.)