* [13/13] arc: do not use __print_symbol()
@ 2017-12-11 12:50 Sergey Senozhatsky
0 siblings, 0 replies; 3+ messages in thread
From: Sergey Senozhatsky @ 2017-12-11 12:50 UTC (permalink / raw)
To: Andrew Morton, Russell King, Catalin Marinas, Mark Salter,
Tony Luck, David Howells, Yoshinori Sato, Guan Xuetao,
Borislav Petkov, Greg Kroah-Hartman, Thomas Gleixner,
Peter Zijlstra, Vineet Gupta, Fengguang Wu
Cc: Steven Rostedt, Petr Mladek, LKML, linux-arm-kernel,
linux-c6x-dev, linux-ia64, linux-am33-list, linux-sh, linux-edac,
x86, linux-snps-arc, Sergey Senozhatsky, Sergey Senozhatsky
__print_symbol() uses extra stack space to sprintf() symbol
information and then to feed that buffer to printk()
char buffer[KSYM_SYMBOL_LEN];
sprint_symbol(buffer, address);
printk(fmt, buffer);
Replace __print_symbol() with a direct printk("%pS") call.
Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
Cc: Vineet Gupta <vgupta@synopsys.com>
---
arch/arc/kernel/stacktrace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arc/kernel/stacktrace.c b/arch/arc/kernel/stacktrace.c
index 74315f302971..bf40e06f3fb8 100644
--- a/arch/arc/kernel/stacktrace.c
+++ b/arch/arc/kernel/stacktrace.c
@@ -163,7 +163,7 @@ arc_unwind_core(struct task_struct *tsk, struct pt_regs *regs,
*/
static int __print_sym(unsigned int address, void *unused)
{
- __print_symbol(" %s\n", address);
+ printk(" %pS\n", (void *)address);
return 0;
}
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [13/13] arc: do not use __print_symbol()
@ 2017-12-11 16:28 Vineet Gupta
0 siblings, 0 replies; 3+ messages in thread
From: Vineet Gupta @ 2017-12-11 16:28 UTC (permalink / raw)
To: Sergey Senozhatsky, Andrew Morton, Russell King, Catalin Marinas,
Mark Salter, Tony Luck, David Howells, Yoshinori Sato,
Guan Xuetao, Borislav Petkov, Greg Kroah-Hartman, Thomas Gleixner,
Peter Zijlstra, Vineet Gupta, Fengguang Wu
Cc: Steven Rostedt, Petr Mladek, LKML,
linux-arm-kernel@lists.infradead.org, linux-c6x-dev@linux-c6x.org,
linux-ia64@vger.kernel.org, linux-am33-list@redhat.com,
linux-sh@vger.kernel.org, linux-edac@vger.kernel.org,
x86@kernel.org, linux-snps-arc@lists.infradead.org,
Sergey Senozhatsky
On 12/11/2017 04:53 AM, Sergey Senozhatsky wrote:
> __print_symbol() uses extra stack space to sprintf() symbol
> information and then to feed that buffer to printk()
>
> char buffer[KSYM_SYMBOL_LEN];
>
> sprint_symbol(buffer, address);
> printk(fmt, buffer);
>
> Replace __print_symbol() with a direct printk("%pS") call.
>
> Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
> Cc: Vineet Gupta <vgupta@synopsys.com>
Applied to arc for-curr
Thx,
-Vineet
> ---
> arch/arc/kernel/stacktrace.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arc/kernel/stacktrace.c b/arch/arc/kernel/stacktrace.c
> index 74315f302971..bf40e06f3fb8 100644
> --- a/arch/arc/kernel/stacktrace.c
> +++ b/arch/arc/kernel/stacktrace.c
> @@ -163,7 +163,7 @@ arc_unwind_core(struct task_struct *tsk, struct pt_regs *regs,
> */
> static int __print_sym(unsigned int address, void *unused)
> {
> - __print_symbol(" %s\n", address);
> + printk(" %pS\n", (void *)address);
> return 0;
> }
>
---
To unsubscribe from this list: send the line "unsubscribe linux-edac" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* [13/13] arc: do not use __print_symbol()
@ 2017-12-12 2:41 Sergey Senozhatsky
0 siblings, 0 replies; 3+ messages in thread
From: Sergey Senozhatsky @ 2017-12-12 2:41 UTC (permalink / raw)
To: Vineet Gupta
Cc: Sergey Senozhatsky, Andrew Morton, Russell King, Catalin Marinas,
Mark Salter, Tony Luck, David Howells, Yoshinori Sato,
Guan Xuetao, Borislav Petkov, Greg Kroah-Hartman, Thomas Gleixner,
Peter Zijlstra, Fengguang Wu, Steven Rostedt, Petr Mladek, LKML,
linux-arm-kernel@lists.infradead.org, linux-c6x-dev@linux-c6x.org,
linux-ia64@vger.kernel.org, linux-am33-list@redhat.com,
linux-sh@vger.kernel.org, linux-edac@vger.kernel.org,
x86@kernel.org, linux-snps-arc@lists.infradead.org,
Sergey Senozhatsky
On (12/11/17 08:28), Vineet Gupta wrote:
> On 12/11/2017 04:53 AM, Sergey Senozhatsky wrote:
> > __print_symbol() uses extra stack space to sprintf() symbol
> > information and then to feed that buffer to printk()
> >
> > char buffer[KSYM_SYMBOL_LEN];
> >
> > sprint_symbol(buffer, address);
> > printk(fmt, buffer);
> >
> > Replace __print_symbol() with a direct printk("%pS") call.
> >
> > Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
> > Cc: Vineet Gupta <vgupta@synopsys.com>
>
> Applied to arc for-curr
thanks.
-ss
---
To unsubscribe from this list: send the line "unsubscribe linux-edac" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-12-12 2:41 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-12 2:41 [13/13] arc: do not use __print_symbol() Sergey Senozhatsky
-- strict thread matches above, loose matches on Subject: below --
2017-12-11 16:28 Vineet Gupta
2017-12-11 12:50 Sergey Senozhatsky
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).