Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-only */
0002 /*
0003  * Copyright (C) 2012 ARM Ltd.
0004  */
0005 #ifndef __ASM_SPARSEMEM_H
0006 #define __ASM_SPARSEMEM_H
0007 
0008 #define MAX_PHYSMEM_BITS    CONFIG_ARM64_PA_BITS
0009 
0010 /*
0011  * Section size must be at least 512MB for 64K base
0012  * page size config. Otherwise it will be less than
0013  * (MAX_ORDER - 1) and the build process will fail.
0014  */
0015 #ifdef CONFIG_ARM64_64K_PAGES
0016 #define SECTION_SIZE_BITS 29
0017 
0018 #else
0019 
0020 /*
0021  * Section size must be at least 128MB for 4K base
0022  * page size config. Otherwise PMD based huge page
0023  * entries could not be created for vmemmap mappings.
0024  * 16K follows 4K for simplicity.
0025  */
0026 #define SECTION_SIZE_BITS 27
0027 #endif /* CONFIG_ARM64_64K_PAGES */
0028 
0029 #endif