From: guoren@kernel.org
To: palmerdabbelt@google.com, paul.walmsley@sifive.com,
mhiramat@kernel.org, alankao@andestech.com, rostedt@goodmis.org,
bjorn.topel@intel.com, pdp7pdp7@gmail.com
Cc: me@packi.ch, Guo Ren <guoren@linux.alibaba.com>,
anup@brainfault.org, linux-kernel@vger.kernel.org,
linux-csky@vger.kernel.org, guoren@kernel.org,
zong.li@sifive.com, greentime.hu@sifive.com,
linux-riscv@lists.infradead.org
Subject: [PATCH v5 3/9] riscv: Fixup wrong ftrace remove cflag
Date: Thu, 17 Dec 2020 16:01:39 +0000 [thread overview]
Message-ID: <1608220905-1962-4-git-send-email-guoren@kernel.org> (raw)
In-Reply-To: <1608220905-1962-1-git-send-email-guoren@kernel.org>
From: Guo Ren <guoren@linux.alibaba.com>
We must use $(CC_FLAGS_FTRACE) instead of directly using -pg. It
will cause -fpatchable-function-entry error.
Signed-off-by: Guo Ren <guoren@linux.alibaba.com>
---
arch/riscv/kernel/Makefile | 4 ++--
arch/riscv/mm/Makefile | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/arch/riscv/kernel/Makefile b/arch/riscv/kernel/Makefile
index fa896c5..27f10eb 100644
--- a/arch/riscv/kernel/Makefile
+++ b/arch/riscv/kernel/Makefile
@@ -4,8 +4,8 @@
#
ifdef CONFIG_FTRACE
-CFLAGS_REMOVE_ftrace.o = -pg
-CFLAGS_REMOVE_patch.o = -pg
+CFLAGS_REMOVE_ftrace.o = $(CC_FLAGS_FTRACE)
+CFLAGS_REMOVE_patch.o = $(CC_FLAGS_FTRACE)
endif
extra-y += head.o
diff --git a/arch/riscv/mm/Makefile b/arch/riscv/mm/Makefile
index c0185e5..6b4b7ec 100644
--- a/arch/riscv/mm/Makefile
+++ b/arch/riscv/mm/Makefile
@@ -2,7 +2,7 @@
CFLAGS_init.o := -mcmodel=medany
ifdef CONFIG_FTRACE
-CFLAGS_REMOVE_init.o = -pg
+CFLAGS_REMOVE_init.o = $(CC_FLAGS_FTRACE)
endif
KCOV_INSTRUMENT_init.o := n
--
2.7.4
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
next prev parent reply other threads:[~2020-12-17 16:03 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-17 16:01 [PATCH v5 0/9] Add k/uprobe & fentry & error_injection supported guoren
2020-12-17 16:01 ` [PATCH v5 1/9] RISC-V: Implement ptrace regs and stack API guoren
2020-12-17 16:01 ` [PATCH v5 2/9] riscv: Fixup compile error BUILD_BUG_ON failed guoren
2020-12-17 16:01 ` guoren [this message]
2020-12-17 16:01 ` [PATCH v5 4/9] riscv: Fixup patch_text panic in ftrace guoren
2020-12-22 20:26 ` Atish Patra
2020-12-17 16:01 ` [PATCH v5 5/9] riscv: Using PATCHABLE_FUNCTION_ENTRY instead of MCOUNT guoren
2020-12-17 16:01 ` [PATCH v5 6/9] riscv: Add kprobes supported guoren
2020-12-17 16:01 ` [PATCH v5 7/9] riscv: Add KPROBES_ON_FTRACE supported guoren
2020-12-17 16:01 ` [PATCH v5 8/9] riscv: Add uprobes supported guoren
2020-12-17 16:01 ` [PATCH v5 9/9] riscv: Add support for function error injection guoren
2021-01-12 19:18 ` [PATCH v5 0/9] Add k/uprobe & fentry & error_injection supported Palmer Dabbelt
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=1608220905-1962-4-git-send-email-guoren@kernel.org \
--to=guoren@kernel.org \
--cc=alankao@andestech.com \
--cc=anup@brainfault.org \
--cc=bjorn.topel@intel.com \
--cc=greentime.hu@sifive.com \
--cc=guoren@linux.alibaba.com \
--cc=linux-csky@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=me@packi.ch \
--cc=mhiramat@kernel.org \
--cc=palmerdabbelt@google.com \
--cc=paul.walmsley@sifive.com \
--cc=pdp7pdp7@gmail.com \
--cc=rostedt@goodmis.org \
--cc=zong.li@sifive.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox