
On 04/09/2016 08:34 PM, Simon Glass wrote:
Hi Marek,
On 20 March 2016 at 10:15, Marek Vasut marex@denx.de wrote:
Import unified.h from Linux kernel 4.4.6 , commit 0d1912303e54ed1b2a371be0bba51c384dd57326 . This header file contains macros used in libgcc functions in Linux kernel on ARM and will be needed for the libgcc sync.
Since unified.h defines the W(instr) macro, we must drop this from the macro from memcpy.S , otherwise this triggers a warning about symbol redefinition. In order to keep the changes to unified.h to the minimum, tweak arch/arm/lib/Makefile such that it defines new CONFIG_THUMB2_KERNEL macro, which is already checked by unified.h, only if Thumb build is enabled, but the target does not support Thumb2 . This way we can remove ad-hoc -DMEMSET_NO_THUMB_BUILD and -DMEMCPY_NO_THUMB_BUILD and we do not change the logic.
Signed-off-by: Marek Vasut marex@denx.de Cc: Albert Aribaud albert.u.boot@aribaud.net Cc: Masahiro Yamada yamada.masahiro@socionext.com Cc: Simon Glass sjg@chromium.org Cc: Tom Rini trini@konsulko.com
arch/arm/include/asm/assembler.h | 1 + arch/arm/include/asm/unified.h | 140 +++++++++++++++++++++++++++++++++++++++ arch/arm/lib/Makefile | 6 +- arch/arm/lib/memcpy.S | 6 -- 4 files changed, 144 insertions(+), 9 deletions(-) create mode 100644 arch/arm/include/asm/unified.h
Reviewed-by: Simon Glass sjg@chromium.org
Can we use SPDX?
Yes, done. Thanks!
Best regards, Marek Vasut