arm64: mm: move pte_* macros
authorMark Rutland <mark.rutland@arm.com>
Mon, 25 Jan 2016 11:45:03 +0000 (11:45 +0000)
committerCatalin Marinas <catalin.marinas@arm.com>
Tue, 16 Feb 2016 15:10:45 +0000 (15:10 +0000)
commit053520f7d3923cc6d37afb28f9887cb1e7d77454
tree6b8bc96235ba066aed982ec2cc2b708549ba56f9
parentc1a88e9124a499939ebd8069d5e4d3937f019157
arm64: mm: move pte_* macros

For pmd, pud, and pgd levels of table, functions including p?d_index and
p?d_offset are defined after the p?d_page_vaddr function for the
immediately higher level of table.

The pte functions however are defined much earlier, even though several
rely on the later definition of pmd_page_vaddr. While this isn't
currently a problem as these are macros, it prevents the logical
grouping of later C functions (which cannot rely on prototypes for
functions not yet defined).

Move these definitions after pmd_page_vaddr, for consistency with the
placement of these functions for other levels of table.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Tested-by: Jeremy Linton <jeremy.linton@arm.com>
Cc: Laura Abbott <labbott@fedoraproject.org>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/include/asm/pgtable.h