• Mark Rutland's avatar
    arm64: entry-ftrace.S: avoid open-coded {adr,ldr}_l · 829d2bd1
    Mark Rutland authored
    Some places in the kernel open-code sequences using ADRP for a symbol
    another instruction using a :lo12: relocation for that same symbol.
    These sequences are easy to get wrong, and more painful to read than is
    necessary. For these reasons, it is preferable to use the
    {adr,ldr,str}_l macros for these cases.
    
    This patch makes use of these in entry-ftrace.S, removing open-coded
    sequences using adrp. This results in a minor code change, since a
    temporary register is not used when generating the address for some
    symbols, but this is fine, as the value of the temporary register is not
    used elsewhere.
    Signed-off-by: default avatarMark Rutland <mark.rutland@arm.com>
    Reviewed-by: default avatarArd Biesheuvel <ard.biesheuvel@linaro.org>
    Cc: AKASHI Takahiro <takahiro.akashi@linaro.org>
    Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
    Cc: Catalin Marinas <catalin.marinas@arm.com>
    Cc: Will Deacon <will.deacon@arm.com>
    Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
    829d2bd1
entry-ftrace.S 6.08 KB