sparsemem.h 716 B

1234567891011121314151617181920212223242526
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef ASMARM_SPARSEMEM_H
  3. #define ASMARM_SPARSEMEM_H
  4. #include <asm/memory.h>
  5. /*
  6. * Two definitions are required for sparsemem:
  7. *
  8. * MAX_PHYSMEM_BITS: The number of physical address bits required
  9. * to address the last byte of memory.
  10. *
  11. * SECTION_SIZE_BITS: The number of physical address bits to cover
  12. * the maximum amount of memory in a section.
  13. *
  14. * Eg, if you have 2 banks of up to 64MB at 0x80000000, 0x84000000,
  15. * then MAX_PHYSMEM_BITS is 32, SECTION_SIZE_BITS is 26.
  16. *
  17. * These can be overridden in your mach/memory.h.
  18. */
  19. #if !defined(MAX_PHYSMEM_BITS) || !defined(SECTION_SIZE_BITS)
  20. #define MAX_PHYSMEM_BITS 36
  21. #define SECTION_SIZE_BITS 28
  22. #endif
  23. #endif