ARM development updates:
- more unified assembly conversions for clang - drop obsolete -mauto-it assembler option - remove arm_memory_present in preference to the generic version - remove unused asm/limits.h header - vdso linker update We tried to make the assembler warn if unified syntax was not used, but unfortunately older versions of GCC warn, so the commit had to be reverted. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIVAwUAXNyRJfTnkBvkraxkAQLy9w/+IZ17YCke7L1Lrk/cbV72RbMPEK4LOJD/ H2JP7GNJPa7JXsAohOELtYav6xsOxERtDkHmplcsRkl519kEfKU7wgjFNGoVUHpk s+urcDIkijdNMXHvyBY4pSy54b8OmUAdeGnpgkMfQ+2gmKSTd9iXXOFfAvi8qDGI F13xXCL3XbbC/9tPmSFS04jmseaDIE5qW9GhrQ3n4qmwx5tx3e6IuWZ1G2UPqAly vjIuRKR2PrGW2ORoPklJ1VPjPjV5eaxP9+YPhCMMIH5MtCOM8K+me0ldbZvrSqu1 b1ovjuWrLdFXBVRUI3yRM3aAM83ZuV3jLWF7+2QtDZCAMMND9FnCOTq4cvHW0Hno HVkYmUFJA5nV4Z62K9buR65gA3gFTmbDBO3NupoXw1KdIUONv/vHt9dA1E6tA4iE oaRK60Uoi2a2FzFp+jsDDNGKJP9eMJS3oDmgVa2UOI0L+oyPsZXM95g7+CJ2Yr5G +oLUfDhhWyrYVTjXd6ZZSCqbQgrbrSslxN0nSjcFb/tO7K5zcAWGWRW/KDxjVlvO ElJXgxNa6RvTT6Lt+zDLEFRxWiBfADQYSoQYXrBLSuEG85/7HJg/9gTbbHFEGfBw IqHvBut/wwArNBkkz2OFjyn0z3vrIr5PwdXs2K49ywlfHHvDxGSEovvYv7kFTuTR hVBSmogtt7U= =719N -----END PGP SIGNATURE----- Merge tag 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm Pull ARM updates from Russell King: "ARM development updates: - more unified assembly conversions for clang - drop obsolete -mauto-it assembler option - remove arm_memory_present in preference to the generic version - remove unused asm/limits.h header - vdso linker update We tried to make the assembler warn if unified syntax was not used, but unfortunately older versions of GCC warn, so the commit had to be reverted" * tag 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm: Revert "ARM: 8846/1: warn if divided syntax assembler is used" ARM: 8858/1: vdso: use $(LD) instead of $(CC) to link VDSO ARM: 8855/1: remove unused <asm/limits.h> ARM: 8850/1: use memblocks_present ARM: 8854/1: drop -mauto-it ARM: 8846/1: warn if divided syntax assembler is used ARM: 8853/1: drop WASM to work around LLVM issue ARM: 8852/1: uaccess: use unified assembler language syntax ARM: 8851/1: add TUSERCOND() macro for conditional postfix
This commit is contained in:
Коммит
8c05f3b965
|
@ -116,8 +116,7 @@ endif
|
|||
AFLAGS_NOWARN :=$(call as-option,-Wa$(comma)-mno-warn-deprecated,-Wa$(comma)-W)
|
||||
|
||||
ifeq ($(CONFIG_THUMB2_KERNEL),y)
|
||||
AFLAGS_AUTOIT :=$(call as-option,-Wa$(comma)-mimplicit-it=always,-Wa$(comma)-mauto-it)
|
||||
CFLAGS_ISA :=-mthumb $(AFLAGS_AUTOIT) $(AFLAGS_NOWARN)
|
||||
CFLAGS_ISA :=-mthumb -Wa,-mimplicit-it=always $(AFLAGS_NOWARN)
|
||||
AFLAGS_ISA :=$(CFLAGS_ISA) -Wa$(comma)-mthumb
|
||||
# Work around buggy relocation from gas if requested:
|
||||
ifeq ($(CONFIG_THUMB2_AVOID_R_ARM_THM_JUMP11),y)
|
||||
|
|
|
@ -133,9 +133,11 @@ static inline void modify_domain(unsigned dom, unsigned type) { }
|
|||
* instructions (inline assembly)
|
||||
*/
|
||||
#ifdef CONFIG_CPU_USE_DOMAINS
|
||||
#define TUSER(instr) #instr "t"
|
||||
#define TUSER(instr) TUSERCOND(instr, )
|
||||
#define TUSERCOND(instr, cond) #instr "t" #cond
|
||||
#else
|
||||
#define TUSER(instr) #instr
|
||||
#define TUSER(instr) TUSERCOND(instr, )
|
||||
#define TUSERCOND(instr, cond) #instr #cond
|
||||
#endif
|
||||
|
||||
#else /* __ASSEMBLY__ */
|
||||
|
|
|
@ -110,10 +110,11 @@ futex_atomic_cmpxchg_inatomic(u32 *uval, u32 __user *uaddr,
|
|||
preempt_disable();
|
||||
__ua_flags = uaccess_save_and_enable();
|
||||
__asm__ __volatile__("@futex_atomic_cmpxchg_inatomic\n"
|
||||
" .syntax unified\n"
|
||||
"1: " TUSER(ldr) " %1, [%4]\n"
|
||||
" teq %1, %2\n"
|
||||
" it eq @ explicit IT needed for the 2b label\n"
|
||||
"2: " TUSER(streq) " %3, [%4]\n"
|
||||
"2: " TUSERCOND(str, eq) " %3, [%4]\n"
|
||||
__futex_atomic_ex_table("%5")
|
||||
: "+r" (ret), "=&r" (val)
|
||||
: "r" (oldval), "r" (newval), "r" (uaddr), "Ir" (-EFAULT)
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0 */
|
||||
#ifndef __ASM_PIPE_H
|
||||
#define __ASM_PIPE_H
|
||||
|
||||
#ifndef PAGE_SIZE
|
||||
#include <asm/page.h>
|
||||
#endif
|
||||
|
||||
#define PIPE_BUF PAGE_SIZE
|
||||
|
||||
#endif
|
||||
|
|
@ -135,8 +135,8 @@ static inline void prefetchw(const void *ptr)
|
|||
__asm__ __volatile__(
|
||||
".arch_extension mp\n"
|
||||
__ALT_SMP_ASM(
|
||||
WASM(pldw) "\t%a0",
|
||||
WASM(pld) "\t%a0"
|
||||
"pldw\t%a0",
|
||||
"pld\t%a0"
|
||||
)
|
||||
:: "p" (ptr));
|
||||
}
|
||||
|
|
|
@ -112,10 +112,11 @@ static inline void __user *__uaccess_mask_range_ptr(const void __user *ptr,
|
|||
unsigned long tmp;
|
||||
|
||||
asm volatile(
|
||||
" .syntax unified\n"
|
||||
" sub %1, %3, #1\n"
|
||||
" subs %1, %1, %0\n"
|
||||
" addhs %1, %1, #1\n"
|
||||
" subhss %1, %1, %2\n"
|
||||
" subshs %1, %1, %2\n"
|
||||
" movlo %0, #0\n"
|
||||
: "+r" (safe_ptr), "=&r" (tmp)
|
||||
: "r" (size), "r" (current_thread_info()->addr_limit)
|
||||
|
|
|
@ -182,21 +182,6 @@ int pfn_valid(unsigned long pfn)
|
|||
EXPORT_SYMBOL(pfn_valid);
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_SPARSEMEM
|
||||
static void __init arm_memory_present(void)
|
||||
{
|
||||
}
|
||||
#else
|
||||
static void __init arm_memory_present(void)
|
||||
{
|
||||
struct memblock_region *reg;
|
||||
|
||||
for_each_memblock(memory, reg)
|
||||
memory_present(0, memblock_region_memory_base_pfn(reg),
|
||||
memblock_region_memory_end_pfn(reg));
|
||||
}
|
||||
#endif
|
||||
|
||||
static bool arm_memblock_steal_permitted = true;
|
||||
|
||||
phys_addr_t __init arm_memblock_steal(phys_addr_t size, phys_addr_t align)
|
||||
|
@ -293,7 +278,7 @@ void __init bootmem_init(void)
|
|||
* Sparsemem tries to allocate bootmem in memory_present(),
|
||||
* so must be done after the fixed reservations
|
||||
*/
|
||||
arm_memory_present();
|
||||
memblocks_present();
|
||||
|
||||
/*
|
||||
* sparse_init() needs the bootmem allocator up and running.
|
||||
|
|
|
@ -10,12 +10,12 @@ obj-vdso := $(addprefix $(obj)/, $(obj-vdso))
|
|||
ccflags-y := -fPIC -fno-common -fno-builtin -fno-stack-protector
|
||||
ccflags-y += -DDISABLE_BRANCH_PROFILING
|
||||
|
||||
VDSO_LDFLAGS := -Wl,-Bsymbolic -Wl,--no-undefined -Wl,-soname=linux-vdso.so.1
|
||||
VDSO_LDFLAGS += -Wl,-z,max-page-size=4096 -Wl,-z,common-page-size=4096
|
||||
VDSO_LDFLAGS += -nostdlib -shared
|
||||
VDSO_LDFLAGS += $(call cc-ldoption, -Wl$(comma)--hash-style=sysv)
|
||||
VDSO_LDFLAGS += $(call cc-ldoption, -Wl$(comma)--build-id)
|
||||
VDSO_LDFLAGS += $(call cc-ldoption, -fuse-ld=bfd)
|
||||
ldflags-y = -Bsymbolic --no-undefined -soname=linux-vdso.so.1 \
|
||||
-z max-page-size=4096 -z common-page-size=4096 \
|
||||
-nostdlib -shared \
|
||||
$(call ld-option, --hash-style=sysv) \
|
||||
$(call ld-option, --build-id) \
|
||||
-T
|
||||
|
||||
obj-$(CONFIG_VDSO) += vdso.o
|
||||
extra-$(CONFIG_VDSO) += vdso.lds
|
||||
|
@ -37,8 +37,8 @@ KCOV_INSTRUMENT := n
|
|||
$(obj)/vdso.o : $(obj)/vdso.so
|
||||
|
||||
# Link rule for the .so file
|
||||
$(obj)/vdso.so.raw: $(src)/vdso.lds $(obj-vdso) FORCE
|
||||
$(call if_changed,vdsold)
|
||||
$(obj)/vdso.so.raw: $(obj)/vdso.lds $(obj-vdso) FORCE
|
||||
$(call if_changed,ld)
|
||||
|
||||
$(obj)/vdso.so.dbg: $(obj)/vdso.so.raw $(obj)/vdsomunge FORCE
|
||||
$(call if_changed,vdsomunge)
|
||||
|
@ -48,11 +48,6 @@ $(obj)/%.so: OBJCOPYFLAGS := -S
|
|||
$(obj)/%.so: $(obj)/%.so.dbg FORCE
|
||||
$(call if_changed,objcopy)
|
||||
|
||||
# Actual build commands
|
||||
quiet_cmd_vdsold = VDSO $@
|
||||
cmd_vdsold = $(CC) $(c_flags) $(VDSO_LDFLAGS) \
|
||||
-Wl,-T $(filter %.lds,$^) $(filter %.o,$^) -o $@
|
||||
|
||||
quiet_cmd_vdsomunge = MUNGE $@
|
||||
cmd_vdsomunge = $(objtree)/$(obj)/vdsomunge $< $@
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче