mem.c 496 B

12345678910111213141516171819202122
  1. /*
  2. * Copyright (C) 2002 Jeff Dike (jdike@karaya.com)
  3. * Licensed under the GPL
  4. */
  5. #include "linux/mm.h"
  6. #include "asm/pgtable.h"
  7. #include "mem_user.h"
  8. #include "skas.h"
  9. unsigned long set_task_sizes_skas(unsigned long *task_size_out)
  10. {
  11. /* Round up to the nearest 4M */
  12. unsigned long host_task_size = ROUND_4M((unsigned long)
  13. &host_task_size);
  14. if (!skas_needs_stub)
  15. *task_size_out = host_task_size;
  16. else *task_size_out = CONFIG_STUB_START & PGDIR_MASK;
  17. return host_task_size;
  18. }