03 2011 档案

摘要:.load wmitrace .load Traceprt !wmitrace.searchpath C:\MFLD\I2C_SPB\Debug 阅读全文
posted @ 2011-03-23 17:42 Fan Zhang 阅读(342) 评论(0) 推荐(0)
摘要:bcdedit/set testsigning on 阅读全文
posted @ 2011-03-19 12:00 Fan Zhang 阅读(282) 评论(0) 推荐(0)
摘要:MachHwDetect调用,它其实是个宏,对应i386,它对应着PcHwDetect。 SystemKey = DetectSystem(); /* Detect buses */ DetectPciBios(SystemKey, &BusNumber); DetectApmBios(SystemKey, &BusNumber); DetectPnpBios(SystemKey, &BusNumber); DetectIsaBios(SystemKey, &BusNumber); DetectAcpiBios(SystemKey, &BusNumber 阅读全文
posted @ 2011-03-16 15:15 Fan Zhang 阅读(1401) 评论(0) 推荐(0)
摘要:建立全局PAGE_LOOKUP_TABLE_ITEM类型的数组PageLookupTableAddress,元素个数是TotalPageCount(总共可用页数)。 然后调用MmInitPageLookupTable函数初始化PageLookupTableAddress,并且标记每个元素记录的类型是什么。 MmInitializeHeap初始化Heap 阅读全文
posted @ 2011-03-16 15:05 Fan Zhang 阅读(185) 评论(0) 推荐(0)
摘要:MmInitializeMemoryManager函数是BootMain函数中很重要的一步。 MmInitializeMemoryManager的前面会打印出一段log,代码如下。 #if DBG // Dump the system memory map DPRINTM(DPRINT_MEMORY, "System Memory Map (Base Address, Length, Type):... 阅读全文
posted @ 2011-03-16 11:51 Fan Zhang 阅读(266) 评论(0) 推荐(0)
摘要:1.代码从MBR启动(boot\freeldr\bootsect\dosmbr.asm) 2.转到硬盘启动分区(boot\freeldr\bootsect\fat32.asm),它负责寻找freeldr.sys。找到后加载到0000:8000h,然后找到freeldr.sys的入口地址。 3.代码跳转到_mainCRTStartup代码(boot\freeldr\freeldr\arch\i386... 阅读全文
posted @ 2011-03-15 16:24 Fan Zhang 阅读(371) 评论(0) 推荐(0)
摘要:NTSTATUS CompleteRoutine( IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp, IN PVOID Context ){ PIO_STACK_LOCATION IrpSp; PKEYBOARD_INPUT_DATA KeyData; int numKeys, i; IrpSp = IoGetCurrentIrpStackLocation(... 阅读全文
posted @ 2011-03-14 16:35 Fan Zhang 阅读(399) 评论(0) 推荐(0)
摘要:ObReferenceObjectByName 可以返回任意对象地址。它的本质是使用ObpLookupObjectName对 “\A\B\C”逐级解析。 IoGetDeviceObjectPointer 只能返回设备对象地址。它的本质是调用ZwOpenFile得到设备句柄,然后调用ObReferenceObjectByHandle得到设备对象指针。 阅读全文
posted @ 2011-03-12 12:36 Fan Zhang 阅读(415) 评论(0) 推荐(0)