ANDROID: 16K: Introduce __MAX_PAGE_SIZE macros
For some cases, such as the vDSO layout, the page alignment needs to be know at build time. Introduce __MAX_PAGE_SIZE and friends for use in such scenarios. Bug: 383389337 Bug: 356729201 Change-Id: I216568384efb147c868278318718703099e12e1c Signed-off-by: Kalesh Singh <kaleshsingh@google.com>
This commit is contained in:
committed by
Carlos Llamas
parent
60b3135822
commit
c64a15a595
@@ -22,6 +22,12 @@
|
||||
|
||||
#include <asm/page.h>
|
||||
|
||||
#define __MAX_PAGE_SHIFT 14
|
||||
#define __MAX_PAGE_SIZE (_AC(1,UL) << __MAX_PAGE_SHIFT)
|
||||
#define __MAX_PAGE_MASK (~(__MAX_PAGE_SIZE-1))
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
#include <linux/align.h>
|
||||
#include <linux/jump_label.h>
|
||||
#include <linux/mman.h>
|
||||
@@ -143,4 +149,6 @@ static __always_inline void __filemap_fixup(unsigned long addr, unsigned long pr
|
||||
___filemap_fixup(addr, prot, old_len, new_len);
|
||||
}
|
||||
|
||||
#endif /* !__ASSEMBLY__ */
|
||||
|
||||
#endif /* __LINUX_PAGE_SIZE_COMPAT_H */
|
||||
|
||||
Reference in New Issue
Block a user