/*
 * Stand-Alone RTLinux Memory Allocator
 * 
 * Written by Vicente Esteve LLoret
 * Released under the terms of the GPL Version 2
 *
 */

#include <os.h>
#include <hypervisor.h>
#include <mm.h>
#include <types.h>
#include <lib.h>


extern char _end;
static char *endmem=(char *) &_end;

char *kmalloc(unsigned int size,int type)
{
  char *ptr =  endmem;

  endmem += size;
  
  return ptr;
};


unsigned long GetMemorySize(void)
{
    unsigned long max_pfn = start_info.nr_pages;
  return max_pfn*1024*4; 
};


void init_memory(void)
{
 
	
}

