arm64: lse: fix LSE atomics with LLVM's integrated assembler
stable inclusion from linux-4.19.164 commit 5681cce44cf41dc3eed8fd62b9e299bb57d1cb7b -------------------------------- commit e0d5896b upstream. Unlike gcc, clang considers each inline assembly block to be independent and therefore, when using the integrated assembler for inline assembly, any preambles that enable features must be repeated in each block. This change defines __LSE_PREAMBLE and adds it to each inline assembly block that has LSE instructions, which allows them to be compiled also with clang's assembler. Link: https://github.com/ClangBuiltLinux/linux/issues/671Signed-off-by: NSami Tolvanen <samitolvanen@google.com> Tested-by: NAndrew Murray <andrew.murray@arm.com> Tested-by: NKees Cook <keescook@chromium.org> Reviewed-by: NAndrew Murray <andrew.murray@arm.com> Reviewed-by: NKees Cook <keescook@chromium.org> Reviewed-by: NNick Desaulniers <ndesaulniers@google.com> Signed-off-by: NWill Deacon <will@kernel.org> [nd: backport adjusted due to missing: commit addfc386 ("arm64: atomics: avoid out-of-line ll/sc atomics")] Signed-off-by: NNick Desaulniers <ndesaulniers@google.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: NYang Yingliang <yangyingliang@huawei.com> Signed-off-by: NCheng Jian <cj.chengjian@huawei.com>
Showing
想要评论请 注册 或 登录