/* * memory_info.c * * Created on: Aug 27, 2011 * Author: Tiberiu */ #include // MemoryGetFree(), MemoryGetTotal(), MemoryGet blah blah... // Returns total physical memory in bytes uint32 MemoryGetTotal() { return (TotalMemory); } // Returns total free physical memory in bytes uint32 MemoryGetFree() { return (TotalFrames - UsedFrames) * 0x4; } // Total used physical memory in bytes uint32 MemoryGetUsed() { return UsedFrames * 0x4; } // Same as above functions, but in frames uint32 MemoryGetFrameSize() { return 0x1000; } uint32 MemoryGetFramesTotal() { return TotalFrames; } uint32 MemoryGetFramesUsed() { return UsedFrames; } uint32 MemoryGetFramesFree() { return (TotalFrames - UsedFrames); }