lparmap.c 908 B

12345678910111213141516171819202122232425262728293031
  1. /*
  2. * Copyright (C) 2005 Stephen Rothwell IBM Corp.
  3. *
  4. * This program is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU General Public License
  6. * as published by the Free Software Foundation; either version
  7. * 2 of the License, or (at your option) any later version.
  8. */
  9. #include <asm/mmu.h>
  10. #include <asm/pgtable.h>
  11. #include <asm/iseries/lpar_map.h>
  12. const struct LparMap __attribute__((__section__(".text"))) xLparMap = {
  13. .xNumberEsids = HvEsidsToMap,
  14. .xNumberRanges = HvRangesToMap,
  15. .xSegmentTableOffs = STAB0_PAGE,
  16. .xEsids = {
  17. { .xKernelEsid = GET_ESID(PAGE_OFFSET),
  18. .xKernelVsid = KERNEL_VSID(PAGE_OFFSET), },
  19. { .xKernelEsid = GET_ESID(VMALLOC_START),
  20. .xKernelVsid = KERNEL_VSID(VMALLOC_START), },
  21. },
  22. .xRanges = {
  23. { .xPages = HvPagesToMap,
  24. .xOffset = 0,
  25. .xVPN = KERNEL_VSID(PAGE_OFFSET) << (SID_SHIFT - HW_PAGE_SHIFT),
  26. },
  27. },
  28. };