[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220819025522.154189-1-lihuafei1@huawei.com>
Date: Fri, 19 Aug 2022 10:55:21 +0800
From: Li Huafei <lihuafei1@...wei.com>
To: <guoren@...nel.org>, <mhiramat@...nel.org>, <palmer@...belt.com>
CC: <rostedt@...dmis.org>, <mingo@...hat.com>,
<paul.walmsley@...ive.com>, <aou@...s.berkeley.edu>,
<naveen.n.rao@...ux.ibm.com>, <anil.s.keshavamurthy@...el.com>,
<davem@...emloft.net>, <jszhang@...nel.org>,
<peterz@...radead.org>, <liaochang1@...wei.com>, <me@...ki.ch>,
<penberg@...nel.org>, <linux-riscv@...ts.infradead.org>,
<linux-kernel@...r.kernel.org>
Subject: [PATCH v2 1/2] riscv: ftrace: Fix the comments about the number of ftrace instruction
When DYNAMIC_FTRACE is enabled, we put 8 16-bit instructions in front of
the function for ftrace use, not 5.
Fixes: afc76b8b8011 ("riscv: Using PATCHABLE_FUNCTION_ENTRY instead of MCOUNT")
Suggested-by: Guo Ren <guoren@...nel.org>
Signed-off-by: Li Huafei <lihuafei1@...wei.com>
---
v1: https://lore.kernel.org/lkml/20220426015751.88582-1-lihuafei1@huawei.com/
Changlog in v1 -> v2:
- Add the fix tag.
- Delete the expression "4 instructions".
arch/riscv/kernel/ftrace.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/riscv/kernel/ftrace.c b/arch/riscv/kernel/ftrace.c
index 2086f6585773..552088e9acc4 100644
--- a/arch/riscv/kernel/ftrace.c
+++ b/arch/riscv/kernel/ftrace.c
@@ -71,8 +71,8 @@ static int __ftrace_modify_call(unsigned long hook_pos, unsigned long target,
}
/*
- * Put 5 instructions with 16 bytes at the front of function within
- * patchable function entry nops' area.
+ * Put 16 bytes at the front of the function within the patchable function
+ * entry nops' area.
*
* 0: REG_S ra, -SZREG(sp)
* 1: auipc ra, 0x?
--
2.17.1
Powered by blists - more mailing lists