Monthly Archives: July 2006

Kernel Memory Management

Compile Time directives: #progma alloc_text(PAGE, AddDevice) #progma data_seg(“PAGEDATA”) #progma code_seg(“PAGE”) … #progma code_seg() Runtime control of pageability MmLockPagableCodeSection MmLockPagableDataSection MmLockPagableSectionByHandle MmPageEntireDriver MmResetDriverPaging MmUnlockPagableImageSection Heap ExAllocatePoolWithTag(type, nBytes, tag) ExFreePool((PVOID) p)

Posted in Windows Kernel |

WDM Driver Object and Device Object

Defined in wdm.h: typedef struct _DRIVER_OBJECT { CSHORT Type; CSHORT Size; PDEVICE_OBJECT DeviceObject; // link list maintained by IO manager … PDRIVER_EXTENSION DriverExtension; // AddDevice … PUNICODE_STRING HardwareDatabase; //registry key for the device … PDRIVER_STARTIO DriverStartIo; // function processes IO … Continue reading

Posted in Windows Driver |

WDM Driver Object and Device Object

Defined in wdm.h: typedef struct _DRIVER_OBJECT { CSHORT Type; CSHORT Size; PDEVICE_OBJECT DeviceObject; // link list maintained by IO manager … PDRIVER_EXTENSION DriverExtension; // AddDevice … PUNICODE_STRING HardwareDatabase; //registry key for the device … PDRIVER_STARTIO DriverStartIo; // function processes IO … Continue reading

Posted in Technology |