[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <cd6c5df5-effd-a1f9-8a25-9f5aac3a92f9@arista.com>
Date: Wed, 6 Nov 2019 16:32:07 +0000
From: Dmitry Safonov <dima@...sta.com>
To: Russell King - ARM Linux admin <linux@...linux.org.uk>
Cc: linux-kernel@...r.kernel.org,
Dmitry Safonov <0x7f454c46@...il.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Ingo Molnar <mingo@...nel.org>, Jiri Slaby <jslaby@...e.com>,
Petr Mladek <pmladek@...e.com>,
Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
Steven Rostedt <rostedt@...dmis.org>,
Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>,
Will Deacon <will@...nel.org>,
linux-arm-kernel@...ts.infradead.org,
clang-built-linux@...glegroups.com
Subject: Re: [PATCH 05/50] arm: Add loglvl to unwind_backtrace()
On 11/6/19 9:12 AM, Russell King - ARM Linux admin wrote:
> On Wed, Nov 06, 2019 at 03:04:56AM +0000, Dmitry Safonov wrote:
>> diff --git a/arch/arm/kernel/traps.c b/arch/arm/kernel/traps.c
>> index 7c3f32b26585..69e35462c9e9 100644
>> --- a/arch/arm/kernel/traps.c
>> +++ b/arch/arm/kernel/traps.c
>> @@ -202,7 +202,7 @@ static void dump_instr(const char *lvl, struct pt_regs *regs)
>> #ifdef CONFIG_ARM_UNWIND
>> static inline void dump_backtrace(struct pt_regs *regs, struct task_struct *tsk)
>> {
>> - unwind_backtrace(regs, tsk);
>> + unwind_backtrace(regs, tsk, KERN_DEBUG);
>
> Why demote this to debug level? This is used as part of the kernel
> panic message, surely we don't want this at debug level? What about
> the non-unwind version?
Right, I wanted to keep the old loglevel in this patch - KERN_DEFAULT.
But got confused with log level in unwind_backtrace().
Will fix.
[..]
>> diff --git a/arch/arm/kernel/unwind.c b/arch/arm/kernel/unwind.c
>> index 0a65005e10f0..caaae1b6f721 100644
>> --- a/arch/arm/kernel/unwind.c
>> +++ b/arch/arm/kernel/unwind.c
>> @@ -455,11 +455,12 @@ int unwind_frame(struct stackframe *frame)
>> return URC_OK;
>> }
>>
>> -void unwind_backtrace(struct pt_regs *regs, struct task_struct *tsk)
>> +void unwind_backtrace(struct pt_regs *regs, struct task_struct *tsk,
>> + const char *loglvl)
>> {
>> struct stackframe frame;
>>
>> - pr_debug("%s(regs = %p tsk = %p)\n", __func__, regs, tsk);
>> + printk("%s%s(regs = %p tsk = %p)\n", loglvl, __func__, regs, tsk);
>
> Clearly, this isn't supposed to be part of the normal backtrace output...
Yes, sorry it's debug for a backtrace - will return pr_debug() for the
message.
Thanks,
Dmitry
Powered by blists - more mailing lists