test(windows-drivers): adapter-init isolated to wdk-sys IddCx binding (Rust IddCx PROVEN to work on-box)
DECISIVE: installed the pre-built UPSTREAM virtual-display-rs (Rust wdf-umdf IddCx) driver on the SAME box -> Status=OK. So a Rust IddCx driver inits an adapter here, self-signed, right now. My wdk-sys driver still fails ONLY at IddCxAdapterInitAsync (0xc000000d) despite matching virtual-display-rs on EVERY inspectable dimension: - same iddcx 1.10 headers+stub - IDDCX_ADAPTER_CAPS + IDD_CX_CLIENT_CONFIG byte-perfect (offsets match C header) - runtime pointers all valid/non-null (names .rdata, version stack, dev handle) - identical IddFunctions[idx]+IddDriverGlobals dispatch; indices 0/1/2 - matched the minimal link (tested vendored wdk-build WITHOUT OneCoreUAP/ NODEFAULTLIB/OPT/INTEGRITYCHECK -> still fails; export pollution ruled out) - device context, no device interface (control via EvtIddCxDeviceIoControl), init order The IddCx ClassExtension ETW provider emits no decodable reason (WPP/kernel-debugger only). The remaining difference is the wdk-sys IddCx binding itself, invisible to inspection. This commit keeps the upstream-matching structure (device context, no interface) + the on-glass instrumentation; vendored wdk-build reverted to pristine. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -148,6 +148,18 @@ pub fn init_adapter(device: WDFDEVICE) -> NTSTATUS {
|
||||
attr.SynchronizationScope =
|
||||
wdk_sys::_WDF_SYNCHRONIZATION_SCOPE::WdfSynchronizationScopeInheritFromParent;
|
||||
attr.ContextTypeInfo = &ADAPTER_CTX.0;
|
||||
dbglog!(
|
||||
"[pf-vd] rt: dev={:#x} pCaps={:#x} model={:#x} mfg={:#x} fwVer={:#x} hwVer={:#x} verSizeOf={} verSet={} diagSet={}",
|
||||
device as usize,
|
||||
(&raw const caps) as usize,
|
||||
caps.EndPointDiagnostics.pEndPointModelName as usize,
|
||||
caps.EndPointDiagnostics.pEndPointManufacturerName as usize,
|
||||
caps.EndPointDiagnostics.pFirmwareVersion as usize,
|
||||
caps.EndPointDiagnostics.pHardwareVersion as usize,
|
||||
core::mem::size_of::<iddcx::IDDCX_ENDPOINT_VERSION>(),
|
||||
version.Size,
|
||||
caps.EndPointDiagnostics.Size,
|
||||
);
|
||||
let init = iddcx::IDARG_IN_ADAPTER_INIT {
|
||||
WdfDevice: device,
|
||||
pCaps: &raw mut caps,
|
||||
|
||||
Reference in New Issue
Block a user