Bugcheck 0xBE during driver unload: nt!MiMarkKernelImageRetpolineBits writes to a read-only page ================================================================================================ Windows 10 Home 22H2, build 19045.6456 (kernel 10.0.19041.6456) | Crash: 2026-11-10 21:31:17.596 UTC+8 | WER report: e11f0b4e-539d-43fc-bb3a-fc492bb94d3b 1. SYMPTOM ---------- The machine bugchecks while a kernel driver is being unloaded by the Service Control Manager (services.exe -> NtUnloadDriver). The fault is inside the kernel's own MiMarkKernelImageRetpolineBits path, which writes to a page that is already read-only (PTE has R/W=0 and NX=1). The bugcheck is therefore an image-unload use-after-free / write-after-free, not a fault in the driver being unloaded. 2. BUGCHECK DATA ---------------- BUGCHECK_CODE : 0xBE (ATTEMPTED_WRITE_TO_READONLY_MEMORY) BUGCHECK_P1 : ffffd5f9e900f02a (address written) BUGCHECK_P2 : 8a00000010100121 (PTE: present, R/W=0, NX=1, PFN 0x10100) BUGCHECK_P3 : ffff99870fbb9b00 BUGCHECK_P4 : 0x000000000000000b PROCESS_NAME : services.exe FAULTING_THREAD : ffffd78f2e7aa640 IMAGE_NAME : ntkrnlmp.exe IMAGE_VERSION : 10.0.19041.6456 SYMBOL_NAME : nt!MiSystemFault+0x1b71d9 FAILURE_BUCKET_ID : AV_nt!MiSystemFault 3. SYMBOLIZED CALL STACK (WinDbg 10.0.29680.1004, Microsoft symbol server) ---------------------------------------------------------------------- nt!memset+0x30 nt!RtlClearBitsEx+0x98 nt!MiMarkRetpolineBits+0x63 nt!MiMarkKernelImageRetpolineBits+0x34 nt!MiUnloadSystemImage nt!MmUnloadSystemImage+0x41 nt!IopDeleteDriver+0x4e nt!ObpRemoveObjectRoutine+0x80 nt!ObfDereferenceObjectWithTag+0xc7 nt!IopUnloadDriver+0x250 nt!NtUnloadDriver+0xb nt!KiSystemServiceCopyEnd+0x28 4. ENVIRONMENT -------------- CPU : AMD Ryzen 7 7700 (8C/16T) Motherboard : BIOSTAR B650MP-E PRO, BIOS 5.34 (2024-04-26) Memory : 32 GB DDR5 (2 x 16 GB Asgard DDR5-6800 kit, running 6000 MT/s, 1.40 V XMP) GPU : NVIDIA GeForce RTX 4070 SUPER, driver 621.01; AMD iGPU driver also installed Security software : Huorong 6.0.0.3 (loaded, not on the crash stack) Hypervisor : none (VBS / Hyper-V disabled) 5. ANALYSIS NOTES ------------------ [1] MiMarkKernelImageRetpolineBits clears retpoline-related bits in the bitmap that tracks the image's executable sections. The bitmap page at ffffd5f9e900f02a was already read-only and NX when RtlClearBitsEx wrote to it, so the page had already been freed or retired while the unload path still held a reference. [2] The dump's unloaded-module list shows EasyAntiCheat as the most recently unloaded image, consistent with the call path (driver object ffffd78f194b2720, already torn down when inspected). [3] The same machine has a longer history of instability (34 unexpected shutdowns and several bugchecks since 2025-12: 0x101, three 0x10E, two 0x117 video TDRs). Those are separate events, but they show how often drivers are loaded and unloaded on this system. 6. QUESTIONS ------------ 1) Is a 0xBE in MiMarkKernelImageRetpolineBits / MiUnloadSystemImage during driver unload a known defect for build 19045.6456, and is it addressed in a later cumulative update? 2) If it is a known issue, which KB fixes it? 3) If it is not known, the minidump (3.6 MB) and the full kernel dump (2.5 GB) are available for analysis, together with the WinDbg !analyze -v output. ATTACHMENTS ----------- 111026-7296-01.dmp (3.6 MB minidump) MEMORY.DMP (2.5 GB full kernel dump, available on request) WinDbg !analyze -v log (text)