Skip to contentSkip to conversation

x86/dumpstack: make show_trace_log_lvl() static

PATCH Applied Hui Su 3 participants 3 messages Nov 13, 2020 – Nov 20, 2020

Subsystems (2)
lore
Share & tools
lore

Hui Su

author
#0 lore raw

PATCH 1/1 x86/dumpstack: make show_trace_log_lvl() static

show_trace_log_lvl() won't be used by other files, so make it static and remove the declaration from the header file.

---
 arch/x86/include/asm/stacktrace.h | 3 ---
 arch/x86/kernel/dumpstack.c       | 2 +-
 2 files changed, 1 insertion(+), 4 deletions(-)
arch/x86/include/asm/stacktrace.h +0 -3
index 49600643faba..f248eb2ac2d4 100644
@@ -88,9 +88,6 @@ get_stack_pointer(struct task_struct *task, struct pt_regs *regs)
 	return (unsigned long *)task->thread.sp;
 }
 
-void show_trace_log_lvl(struct task_struct *task, struct pt_regs *regs,
-			unsigned long *stack, const char *log_lvl);
-
 /* The form of the top of the frame on the stack */
 struct stack_frame {
 	struct stack_frame *next_frame;
arch/x86/kernel/dumpstack.c +1 -1
index 25c06b67e7e0..067de0d0fa4f 100644
@@ -168,7 +168,7 @@ static void show_regs_if_on_stack(struct stack_info *info, struct pt_regs *regs,
 	}
 }
 
-void show_trace_log_lvl(struct task_struct *task, struct pt_regs *regs,
+static void show_trace_log_lvl(struct task_struct *task, struct pt_regs *regs,
 			unsigned long *stack, const char *log_lvl)
 {
 	struct unwind_state state;
Signature · 1 line
2.29.0
merge bot Applied
#1 lore raw

[tip: x86/cleanups] x86/dumpstack: Make show_trace_log_lvl() static

The following commit has been merged into the x86/cleanups branch of tip:

The following commit has been merged into the x86/cleanups branch of tip:

Commit-ID:     09a217c10504bcaef911cf2af74e424338efe629
Gitweb:        https://git.kernel.org/tip/09a217c10504bcaef911cf2af74e424338efe629
Author:        Hui Su <[email protected]>
AuthorDate:    Fri, 13 Nov 2020 21:39:43 +08:00
Committer:     Borislav Petkov <[email protected]>
CommitterDate: Tue, 17 Nov 2020 19:05:32 +01:00

x86/dumpstack: Make show_trace_log_lvl() static

show_trace_log_lvl() is not used by other compilation units so make it static and remove the declaration from the header file.

---
 arch/x86/include/asm/stacktrace.h | 3 ---
 arch/x86/kernel/dumpstack.c       | 2 +-
 2 files changed, 1 insertion(+), 4 deletions(-)
arch/x86/include/asm/stacktrace.h +0 -3
index 4960064..f248eb2 100644
@@ -88,9 +88,6 @@ get_stack_pointer(struct task_struct *task, struct pt_regs *regs)
 	return (unsigned long *)task->thread.sp;
 }
 
-void show_trace_log_lvl(struct task_struct *task, struct pt_regs *regs,
-			unsigned long *stack, const char *log_lvl);
-
 /* The form of the top of the frame on the stack */
 struct stack_frame {
 	struct stack_frame *next_frame;
arch/x86/kernel/dumpstack.c +1 -1
index 25c06b6..067de0d 100644
@@ -168,7 +168,7 @@ static void show_regs_if_on_stack(struct stack_info *info, struct pt_regs *regs,
 	}
 }
 
-void show_trace_log_lvl(struct task_struct *task, struct pt_regs *regs,
+static void show_trace_log_lvl(struct task_struct *task, struct pt_regs *regs,
 			unsigned long *stack, const char *log_lvl)
 {
 	struct unwind_state state;