From: Josh Poimboeuf <jpoimboe@redhat.com>
To: Dave Jones <davej@codemonkey.org.uk>
Cc: Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: stack unwinder warning.
Date: Fri, 6 Jan 2017 10:50:32 -0600 [thread overview]
Message-ID: <20170106165032.gnu237llyg3wk54r@treble> (raw)
In-Reply-To: <20170106050947.k3o5wxdandbqk7cb@codemonkey.org.uk>
On Fri, Jan 06, 2017 at 12:09:47AM -0500, Dave Jones wrote:
> On Thu, Jan 05, 2017 at 11:02:14AM -0600, Josh Poimboeuf wrote:
> > On Thu, Jan 05, 2017 at 08:52:49AM -0600, Josh Poimboeuf wrote:
> > > On Tue, Dec 27, 2016 at 02:00:30PM -0500, Dave Jones wrote:
> > > > I'm not sure what to make of this. Josh ? (4.10-rc1)
> > > >
> > > > WARNING: kernel stack frame pointer at ffffc900003e7858 in trinity-c6:29122 has bad value ffffffff82103a80
> > > > unwind stack type:0 next_sp: (null) mask:2 graph_idx:0
> > > > ffffc900003e7808: ffffffff811a02e5 (ring_buffer_lock_reserve+0x1d5/0x580)
> > > > ffffc900003e7810: ffffffff8119adc3 (rb_commit+0x93/0x350)
> > > > ffffc900003e7818: ffffffff811b31d4 (function_trace_call+0x104/0x1f0)
> > > > ffffc900003e7820: ffff8804f10ec000 (0xffff8804f10ec000)
> > > > ffffc900003e7828: 0000000000000000 ...
> > > > ffffc900003e7830: ffffffff8119b3ae (ring_buffer_unlock_commit+0x8e/0x120)
> > > > ffffc900003e7838: 0000000000000001 (0x1)
> > > > ffffc900003e7840: ffffea0002854e00 (0xffffea0002854e00)
> > > > ffffc900003e7848: 000000000000000a (0xa)
> > > > ffffc900003e7850: ffffea0002854ec0 (0xffffea0002854ec0)
> > > > ffffc900003e7858: ffffea000287c480 (0xffffea000287c480)
> > >
> > > The value reported by the warning contradicts the value reported by the
> > > dump. So this seems to have been caused by dumping the stack of a task
> > > which is running on another CPU. There are still some places in the
> > > code where that's possible. So I'm going to need to remove these
> > > unwinder warnings for now.
> >
> > I'll be submitting the following patch soon, which I think should
> > silence the warning. If the warning is recreatable, would you mind
> > testing it?
>
> I didn't wait long enough..
>
> WARNING: kernel stack frame pointer at ffffc90001443f30 in kworker/u8:8:30468 has bad value (null)
> unwind stack type:0 next_sp: (null) mask:6 graph_idx:0
This is actually a separate issue. The below patch should fix it.
Would you mind running it for a bit along with the other patch?
diff --git a/arch/x86/entry/entry_64.S b/arch/x86/entry/entry_64.S
index 5b21970..044d18e 100644
--- a/arch/x86/entry/entry_64.S
+++ b/arch/x86/entry/entry_64.S
@@ -36,6 +36,7 @@
#include <asm/smap.h>
#include <asm/pgtable_types.h>
#include <asm/export.h>
+#include <asm/frame.h>
#include <linux/err.h>
.code64
@@ -408,17 +409,19 @@ END(__switch_to_asm)
* r12: kernel thread arg
*/
ENTRY(ret_from_fork)
+ FRAME_BEGIN /* help unwinder find end of stack */
movq %rax, %rdi
- call schedule_tail /* rdi: 'prev' task parameter */
+ call schedule_tail /* rdi: 'prev' task parameter */
- testq %rbx, %rbx /* from kernel_thread? */
- jnz 1f /* kernel threads are uncommon */
+ testq %rbx, %rbx /* from kernel_thread? */
+ jnz 1f /* kernel threads are uncommon */
2:
- movq %rsp, %rdi
+ leaq FRAME_OFFSET(%rsp),%rdi /* pt_regs pointer */
call syscall_return_slowpath /* returns with IRQs disabled */
TRACE_IRQS_ON /* user mode is traced as IRQS on */
SWAPGS
+ FRAME_END
jmp restore_regs_and_iret
1:
next prev parent reply other threads:[~2017-01-06 16:50 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-27 19:00 Dave Jones
2017-01-05 14:52 ` Josh Poimboeuf
2017-01-05 17:02 ` Josh Poimboeuf
2017-01-05 17:08 ` Dave Jones
2017-01-05 23:50 ` Dave Jones
2017-01-06 5:09 ` Dave Jones
2017-01-06 16:50 ` Josh Poimboeuf [this message]
2017-01-08 0:08 ` Dave Jones
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=20170106165032.gnu237llyg3wk54r@treble \
--to=jpoimboe@redhat.com \
--cc=davej@codemonkey.org.uk \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®