Author: fireball
Date: Fri Oct 12 01:07:47 2007
New Revision: 29520
URL:
http://svn.reactos.org/svn/reactos?rev=29520&view=rev
Log:
- Fix a long standing bug, which prevented NT to work stable (in fact, it died very soon
after booting). The bug was in occasional placing Gdt and Idt into a temporary heap,
instead of MemoryData marked area of memory. The possibility of this bug was suggested
long time ago by Alex, but I didn't believe him back then :)
- Now Windows NT works quite good after booting via WinLdr in QEMU.
Modified:
branches/winldr/windows/winldr.c
Modified: branches/winldr/windows/winldr.c
URL:
http://svn.reactos.org/svn/reactos/branches/winldr/windows/winldr.c?rev=295…
==============================================================================
--- branches/winldr/windows/winldr.c (original)
+++ branches/winldr/windows/winldr.c Fri Oct 12 01:07:47 2007
@@ -232,7 +232,7 @@
/* Allocate space for new GDT + IDT */
BlockSize = NUM_GDT*sizeof(KGDTENTRY) + NUM_IDT*sizeof(KIDTENTRY);//FIXME: Use GDT/IDT
limits here?
NumPages = (BlockSize + MM_PAGE_SIZE - 1) >> MM_PAGE_SHIFT;
- *GdtIdt = (PKGDTENTRY)MmAllocateMemory(NumPages * MM_PAGE_SIZE);
+ *GdtIdt = (PKGDTENTRY)MmAllocateMemoryWithType(NumPages * MM_PAGE_SIZE,
LoaderMemoryData);
if (*GdtIdt == NULL)
{