ANDROID: arm-smccc: fix clang build
authorGreg Hackmann <ghackmann@google.com>
Fri, 2 Mar 2018 21:22:46 +0000 (13:22 -0800)
committerGreg Hackmann <ghackmann@google.com>
Tue, 20 Mar 2018 18:29:32 +0000 (11:29 -0700)
commite707f486c525bd4cf106e408b0a6ee1b3a3e9fd0
treed2ce1655f4de34373b8051da7b895a146170eba8
parentfdcb8f51789a70e62c0ffab7e0f640a409ef307a
ANDROID: arm-smccc: fix clang build

The SMCCC 1.1 helpers rely on an undocumented(?) gcc extension, where
obsolete AArch32 register names are accepted in AArch64 mode and
silently changed to X[n] or W[n] based on context.

There's ongoing discussion upstream about how to move forward on this
(https://lkml.org/lkml/2018/2/28/1175, https://lkml.org/lkml/2018/3/16/876).
In the meantime, to unbreak the android-4.14 build on clang, we'll
temporary switch to using X[n] instead of R[n] on ARM64: these helpers
were introduced to 4.14.y for two specific callers, and both cases
should use the full 64-bit register width.

Bug: 74579705

Fixes: ac63fdb4a2b2 ("arm/arm64: smccc: Implement SMCCC v1.1 inline primitive")
Change-Id: I1eb14f7b6674f7dffcad9572e409f6bcdba69610
Signed-off-by: Greg Hackmann <ghackmann@google.com>
include/linux/arm-smccc.h