From: Joerg Roedel <joro@8bytes.org>
To: Guo Ren <guoren@kernel.org>
Cc: Guenter Roeck <linux@roeck-us.net>,
linux-csky@vger.kernel.org, linux-kernel@vger.kernel.org,
Joerg Roedel <jroedel@suse.de>
Subject: [PATCH] csky: Fix build with upstream gcc
Date: Tue, 21 Jul 2020 13:23:14 +0200 [thread overview]
Message-ID: <20200721112314.1162-1-joro@8bytes.org> (raw)
From: Joerg Roedel <jroedel@suse.de>
Building a kernel for the CSKY architecture with CONFIG_FRAME_POINTER
set requires a gcc supporting the non-upstream '-mbacktrace' option.
Check for the '-mbacktrace' option before enabling CONFIG_FRAMEPOINTER
and fix building CSKY with an upstream gcc compiler.
Signed-off-by: Joerg Roedel <jroedel@suse.de>
---
arch/csky/Kconfig | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/csky/Kconfig b/arch/csky/Kconfig
index bd31ab12f77d..1622e1c56026 100644
--- a/arch/csky/Kconfig
+++ b/arch/csky/Kconfig
@@ -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
next reply other threads:[~2020-07-21 11:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-21 11:23 Joerg Roedel [this message]
2020-07-21 13:21 [PATCH] csky: Fix build with upstream gcc Guenter Roeck
2020-07-21 16:05 ` Guo Ren
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200721112314.1162-1-joro@8bytes.org \
--to=joro@8bytes.org \
--cc=guoren@kernel.org \
--cc=jroedel@suse.de \
--cc=linux-csky@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.