Much like we have PAGE_OFFSET() there already, there's also no reason for each arch to define identical PAGE_ALIGN().
Signed-off-by: Jan Beulich <jbeul...@suse.com> --- a/xen/arch/arm/include/asm/page.h +++ b/xen/arch/arm/include/asm/page.h @@ -303,8 +303,6 @@ static inline int gva_to_ipa(vaddr_t va, #endif /* __ASSEMBLY__ */ -#define PAGE_ALIGN(x) (((x) + PAGE_SIZE - 1) & PAGE_MASK) - #endif /* __ARM_PAGE_H__ */ /* --- a/xen/arch/x86/include/asm/page.h +++ b/xen/arch/x86/include/asm/page.h @@ -404,8 +404,6 @@ static inline void invalidate_icache(voi #endif /* !__ASSEMBLY__ */ -#define PAGE_ALIGN(x) (((x) + PAGE_SIZE - 1) & PAGE_MASK) - #endif /* __X86_PAGE_H__ */ /* --- a/xen/include/xen/page-size.h +++ b/xen/include/xen/page-size.h @@ -10,7 +10,8 @@ */ #define PAGE_SIZE (_AC(1,L) << PAGE_SHIFT) #define PAGE_MASK (~(PAGE_SIZE-1)) -#define PAGE_OFFSET(ptr) ((unsigned long)(ptr) & ~PAGE_MASK) +#define PAGE_OFFSET(ptr) ((unsigned long)(ptr) & ~PAGE_MASK) +#define PAGE_ALIGN(x) (((x) + PAGE_SIZE - 1) & PAGE_MASK) #define PADDR_MASK ((_AC(1,ULL) << PADDR_BITS) - 1) #define VADDR_MASK (~_AC(0,UL) >> (BITS_PER_LONG - VADDR_BITS))