mem.c 956 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * Copyright (C) 2002 Jeff Dike (jdike@karaya.com)
  3. * Licensed under the GPL
  4. */
  5. #include "linux/config.h"
  6. #include "linux/mm.h"
  7. #include "mem_user.h"
  8. unsigned long set_task_sizes_skas(int arg, unsigned long *host_size_out,
  9. unsigned long *task_size_out)
  10. {
  11. /* Round up to the nearest 4M */
  12. unsigned long top = ROUND_4M((unsigned long) &arg);
  13. #ifdef CONFIG_HOST_TASK_SIZE
  14. *host_size_out = CONFIG_HOST_TASK_SIZE;
  15. *task_size_out = CONFIG_HOST_TASK_SIZE;
  16. #else
  17. *host_size_out = top;
  18. *task_size_out = top;
  19. #endif
  20. return(((unsigned long) set_task_sizes_skas) & ~0xffffff);
  21. }
  22. /*
  23. * Overrides for Emacs so that we follow Linus's tabbing style.
  24. * Emacs will notice this stuff at the end of the file and automatically
  25. * adjust the settings for this buffer only. This must remain at the end
  26. * of the file.
  27. * ---------------------------------------------------------------------------
  28. * Local variables:
  29. * c-file-style: "linux"
  30. * End:
  31. */