csky: Fix build with upstream gcc
Quoted 8 lines · Joerg Roedel
From: Joerg Roedel <[email protected]>
Building a kernel for the CSKY architecture with
CONFIG_FRAME_POINTERset requires a gcc supporting the non-upstream '-mbacktrace' option. Check for the '-mbacktrace' option before enablingCONFIG_FRAMEPOINTERand fix building CSKY with an upstream gcc compiler.Signed-off-by Joerg Roedel <[email protected]>
Reviewed-by Guenter Roeck <[email protected]>
Tested-by Guenter Roeck <[email protected]>
Quoted 29 lines
--- arch/csky/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)arch/csky/Kconfig +2
-2@@ -8,7 +8,7 @@ config CSKY select ARCH_HAS_SYNC_DMA_FOR_DEVICE select ARCH_USE_BUILTIN_BSWAP select ARCH_USE_QUEUED_RWLOCKS if NR_CPUS>2 - select ARCH_WANT_FRAME_POINTERS if !CPU_CK610 + select ARCH_WANT_FRAME_POINTERS if (!CPU_CK610 && STACKTRACE_SUPPORT) select COMMON_CLK select CLKSRC_MMIO select CSKY_MPINTC if CPU_CK860@@ -125,7 +125,7 @@ config MMU def_bool y config STACKTRACE_SUPPORT - def_bool y + def_bool $(success,echo 'int foo(void) { return 0; }' | $(CC) -mbacktrace -x c - -c -o /dev/null) config TIME_LOW_RES def_bool ySignature · 1 line
2.27.0
Thx Joerg & Guenter,
Cool work!
Acked-by Guo Ren <[email protected]>
Approve to next branch.
Quoted 43 lines · Guenter Roeck
Quoted 8 lines · Joerg Roedel
From: Joerg Roedel <[email protected]>
Building a kernel for the CSKY architecture with
CONFIG_FRAME_POINTERset requires a gcc supporting the non-upstream '-mbacktrace' option. Check for the '-mbacktrace' option before enablingCONFIG_FRAMEPOINTERand fix building CSKY with an upstream gcc compiler.Signed-off-by Joerg Roedel <[email protected]>Reviewed-by Guenter Roeck <[email protected]>Tested-by Guenter Roeck <[email protected]>Quoted 29 lines
--- arch/csky/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)arch/csky/Kconfig +2
-3@@ -8,7 +8,7 @@ config CSKY select ARCH_HAS_SYNC_DMA_FOR_DEVICE select ARCH_USE_BUILTIN_BSWAP select ARCH_USE_QUEUED_RWLOCKS if NR_CPUS>2 - select ARCH_WANT_FRAME_POINTERS if !CPU_CK610 + select ARCH_WANT_FRAME_POINTERS if (!CPU_CK610 && STACKTRACE_SUPPORT) select COMMON_CLK select CLKSRC_MMIO select CSKY_MPINTC if CPU_CK860@@ -125,7 +125,7 @@ config MMU def_bool y config STACKTRACE_SUPPORT - def_bool y + def_bool $(success,echo 'int foo(void) { return 0; }' | $(CC) -mbacktrace -x c - -c -o /dev/null) config TIME_LOW_RES def_bool y --2.27.0
Signature · 4 lines
Best Regards Guo Ren ML: https://lore.kernel.org/linux-csky/