Add missing svn:eol-style=native properties

svn path=/trunk/; revision=28805
This commit is contained in:
Hervé Poussineau 2007-09-03 07:39:30 +00:00
parent 39ed067ac8
commit c0614ecb59
3 changed files with 19 additions and 18 deletions

View file

@ -52,9 +52,6 @@ static BOOLEAN FsOpenVolume(ULONG DriveNumber, ULONGLONG StartSector, ULONGLONG
{ {
CHAR ErrorText[80]; CHAR ErrorText[80];
printf("FsOpenVolume: (disk=%d,start=%d,count=%d,type=%d)\n",
DriveNumber, StartSector, SectorCount, Type);
FsType = Type; FsType = Type;
if( !FsStaticBufferDisk ) if( !FsStaticBufferDisk )
@ -165,7 +162,6 @@ PFILE FsOpenFile(PCSTR FileName)
break; break;
} }
#ifdef DEBUG
// //
// Check return value // Check return value
// //
@ -177,7 +173,6 @@ PFILE FsOpenFile(PCSTR FileName)
{ {
DbgPrint((DPRINT_FILESYSTEM, "FsOpenFile() failed.\n")); DbgPrint((DPRINT_FILESYSTEM, "FsOpenFile() failed.\n"));
} }
#endif // defined DEBUG
return FileHandle; return FileHandle;
} }

View file

@ -90,7 +90,10 @@
/* Swap */ /* Swap */
#include <bytesex.h> #include <bytesex.h>
/* arch defines */
#ifdef _X86_
#define Ke386EraseFlags(x) __asm__ __volatile__("pushl $0 ; popfl\n") #define Ke386EraseFlags(x) __asm__ __volatile__("pushl $0 ; popfl\n")
#endif
extern BOOLEAN UserInterfaceUp; /* Tells us if the user interface is displayed */ extern BOOLEAN UserInterfaceUp; /* Tells us if the user interface is displayed */

View file

@ -85,21 +85,24 @@ PVOID MmAllocateMemory(ULONG MemorySize)
// satisfy this allocation // satisfy this allocation
PagesNeeded = ROUND_UP(MemorySize, MM_PAGE_SIZE) / MM_PAGE_SIZE; PagesNeeded = ROUND_UP(MemorySize, MM_PAGE_SIZE) / MM_PAGE_SIZE;
#ifdef _M_PPC
{
// We don't have enough reserve, claim some memory from openfirmware
ULONG ptr;
ptr = ofw_claim(0,MemorySize,MM_PAGE_SIZE);
MemPointer = (PVOID)(ptr);
if (MemPointer)
return MemPointer;
}
#endif
// If we don't have enough available mem // If we don't have enough available mem
// then return NULL // then return NULL
if (FreePagesInLookupTable < PagesNeeded) if (FreePagesInLookupTable < PagesNeeded)
{ {
#ifdef _M_PPC
ULONG ptr;
printf("Allocating %d bytes directly ...\n", MemorySize);
ptr = ofw_claim(0,MemorySize,MM_PAGE_SIZE);
MemPointer = (PVOID)(ptr);
return MemPointer;
#else
DbgPrint((DPRINT_MEMORY, "Memory allocation failed in MmAllocateMemory(). Not enough free memory to allocate %d bytes. AllocationCount: %d\n", MemorySize, AllocationCount)); DbgPrint((DPRINT_MEMORY, "Memory allocation failed in MmAllocateMemory(). Not enough free memory to allocate %d bytes. AllocationCount: %d\n", MemorySize, AllocationCount));
UiMessageBoxCritical("Memory allocation failed: out of memory."); UiMessageBoxCritical("Memory allocation failed: out of memory.");
return NULL; return NULL;
#endif
} }
FirstFreePageFromEnd = MmFindAvailablePages(PageLookupTableAddress, TotalPagesInLookupTable, PagesNeeded, AllocateFromEnd); FirstFreePageFromEnd = MmFindAvailablePages(PageLookupTableAddress, TotalPagesInLookupTable, PagesNeeded, AllocateFromEnd);