1 #include <stdarg.h> 2 #include <stddef.h> 3 #include <stdio.h> 4 #include <string.h> 5 #include <ntverp.h> 6 7 extern "C" { 8 #include <ntddk.h> 9 #include <ntstrsafe.h> 10 } 11 12 #define FX_DYNAMICS_GENERATE_TABLE 1 13 14 #include "fx.hpp" 15 16 // #include <fxldr.h> 17 // #include "fxbugcheck.h" 18 19 20 //----------------------------------------- ------------------------------------ 21 22 extern "C" { 23 24 #include "fxdynamics.h" 25 26 // #include "FxLibraryCommon.h" 27 28 typedef VOID (*WDFFUNC) (VOID); 29 30 const WDFFUNC *WdfFunctions_01017 = (WDFFUNC *)(&WdfVersion.Functions); 31 // DECLSPEC_ALIGN(MAX_NATURAL_ALIGNMENT) UINT8 WdfDriverGlobalsVal[248] = { 0 }; // sizeof(FX_DRIVER_GLOBALS) 32 // PWDF_DRIVER_GLOBALS WdfDriverGlobals = &((PFX_DRIVER_GLOBALS)&WdfDriverGlobalsVal)->Public; 33 WDF_BIND_INFO WdfBindInfo = {0}; 34 PWDF_DRIVER_GLOBALS WdfDriverGlobals; 35 36 #define KMDF_DEFAULT_NAME "Wdf01000" 37 38 PCHAR WdfLdrType = KMDF_DEFAULT_NAME; 39 40 WDFAPI 41 NTSTATUS 42 STDCALL 43 WdfApiNotImplemented() 44 { 45 DbgPrint("ReactOS KMDF: %s non-implemented API called\n"); 46 __debugbreak(); 47 return STATUS_UNSUCCESSFUL; 48 } 49 50 // called in WdfDriverCreate in fxdriverapi.cpp 51 VOID 52 RosInitWdf() 53 { 54 WdfDriverGlobals = FxAllocateDriverGlobals(); 55 PFX_DRIVER_GLOBALS fxDriverGlobals = GetFxDriverGlobals(WdfDriverGlobals); 56 57 WdfBindInfo.Size = sizeof(WDF_BIND_INFO); 58 WdfBindInfo.Version.Major = 1; 59 WdfBindInfo.Version.Minor = 9; 60 WdfBindInfo.Version.Build = 7600; 61 WdfBindInfo.FuncCount = WdfVersion.FuncCount; 62 WdfBindInfo.FuncTable = (WDFFUNC *)(&WdfVersion.Functions); 63 fxDriverGlobals->WdfBindInfo = &WdfBindInfo; 64 } 65 66 void 67 __cxa_pure_virtual() 68 { 69 __debugbreak(); 70 } 71 72 } // extern "C"