From: Sasha Levin <sasha.levin@oracle.com>
To: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>,
Linus Torvalds <torvalds@linux-foundation.org>
Cc: Andrea Arcangeli <aarcange@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>,
shli@kernel.org, Hugh Dickins <hughd@google.com>,
Rik van Riel <riel@redhat.com>, Shaohua Li <shli@fusionio.com>,
linux-mm <linux-mm@kvack.org>
Subject: Re: [patch 019/154] mm: make madvise(MADV_WILLNEED) support swap file prefetch
Date: Mon, 16 Dec 2013 10:18:39 -0500 [thread overview]
Message-ID: <52AF19CF.2060102@oracle.com> (raw)
In-Reply-To: <20131216124754.29063E0090@blue.fi.intel.com>
On 12/16/2013 07:47 AM, Kirill A. Shutemov wrote:
> I probably miss some context here. Do you have crash on some use-case or
> what? Could you point me to start of discussion.
Yes, Sorry, here's the crash that started this discussion originally:
The code points to:
for (index = start; index != end; index += PAGE_SIZE) {
pte_t pte;
swp_entry_t entry;
struct page *page;
spinlock_t *ptl;
orig_pte = pte_offset_map_lock(vma->vm_mm, pmd, start, &ptl); <=== HERE
pte = *(orig_pte + ((index - start) / PAGE_SIZE));
pte_unmap_unlock(orig_pte, ptl);
[ 1840.379128] BUG: unable to handle kernel NULL pointer dereference at (null)
[ 1840.506540] IP: [<ffffffff81199c09>] do_raw_spin_trylock+0x9/0x60
[ 1840.507378] PGD e07f80067 PUD e07f81067 PMD 0
[ 1840.507966] Oops: 0000 [#1] PREEMPT SMP DEBUG_PAGEALLOC
[ 1840.508833] Dumping ftrace buffer:
[ 1840.509859] (ftrace buffer empty)
[ 1840.510187] Modules linked in:
[ 1840.510187] CPU: 10 PID: 39165 Comm: trinity-child10 Not tainted
3.13.0-rc3-next-20131212-sasha-00007-gbcfdb32 #4062
[ 1840.510187] task: ffff880d89feb000 ti: ffff880d8f8dc000 task.ti: ffff880d8f8dc000
[ 1840.510187] RIP: 0010:[<ffffffff81199c09>] [<ffffffff81199c09>] do_raw_spin_trylock+0x9/0x60
[ 1840.510187] RSP: 0018:ffff880d8f8ddc78 EFLAGS: 00010296
[ 1840.510187] RAX: ffff880d89feb000 RBX: 0000000000000000 RCX: 0000000000000000
[ 1840.510187] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
[ 1840.510187] RBP: ffff880d8f8ddc78 R08: 0000000000000000 R09: 0000000000000000
[ 1840.510187] R10: 0000000000000001 R11: 0000000000000000 R12: 0000000000000018
[ 1840.510187] R13: ffff880d91e9c2d8 R14: 00003ffffffff000 R15: ffff880000000000
[ 1840.510187] FS: 00007f394f15e700(0000) GS:ffff880fe0a00000(0000) knlGS:0000000000000000
[ 1840.510187] CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b
[ 1840.510187] CR2: 0000000000000000 CR3: 0000000eb9d7f000 CR4: 00000000000006e0
[ 1840.510187] DR0: 0000000000694000 DR1: 0000000000000000 DR2: 0000000000000000
[ 1840.510187] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000600
[ 1840.510187] Stack:
[ 1840.510187] ffff880d8f8ddca8 ffffffff843b0768 ffffffff8127885f ffffffff843b1725
[ 1840.510187] 00007f390b600000 0000000000000000 ffff880d8f8ddd08 ffffffff8127885f
[ 1840.510187] 0000000000000000 ffff880efc0cc600 00007f390b800000 0000000d190001e0
[ 1840.510187] Call Trace:
[ 1840.510187] [<ffffffff843b0768>] _raw_spin_lock+0x48/0x80
[ 1840.510187] [<ffffffff8127885f>] ? swapin_walk_pmd_entry+0xff/0x250
[ 1840.510187] [<ffffffff843b1725>] ? _raw_spin_unlock+0x35/0x60
[ 1840.510187] [<ffffffff8127885f>] swapin_walk_pmd_entry+0xff/0x250
[ 1840.510187] [<ffffffff81290f98>] walk_pmd_range+0xf8/0x240
[ 1840.510187] [<ffffffff812911e3>] walk_pud_range+0x103/0x150
[ 1840.510187] [<ffffffff81291451>] walk_page_range+0x221/0x2a0
[ 1840.510187] [<ffffffff81278a32>] madvise_willneed+0x82/0x160
[ 1840.510187] [<ffffffff81278760>] ? madvise_hwpoison+0x140/0x140
[ 1840.510187] [<ffffffff81278e3e>] madvise_vma+0x11e/0x1c0
[ 1840.510187] [<ffffffff81279068>] SyS_madvise+0x188/0x250
[ 1840.510187] [<ffffffff843baed0>] tracesys+0xdd/0xe2
[ 1840.510187] Code: 40 00 e8 ab 32 fc ff 84 c0 0f 84 3b ff ff ff 48 83 c4 18 31 c0 5b 41 5c 41 5d
41 5e 41 5f c9 c3 90 90 55 48 89 e5 66 66 66 66 90 <8b> 17 0f b7 ca 89 d0 c1 e8 10 83 e0 fe 39 c1 75
36 8d 8a 00 00
[ 1840.510187] RIP [<ffffffff81199c09>] do_raw_spin_trylock+0x9/0x60
[ 1840.510187] RSP <ffff880d8f8ddc78>
[ 1840.510187] CR2: 0000000000000000
Thanks,
Sasha
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2013-12-16 15:18 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20130223003232.4CDDB5A41B6@corp2gmr1-2.hot.corp.google.com>
[not found] ` <52AA0613.2000908@oracle.com>
[not found] ` <CA+55aFw3_0_Et9bbfWgGLXEUaGQW1HE8j=oGBqFG_8j+h6jmvQ@mail.gmail.com>
[not found] ` <CA+55aFyRZW=Uy9w+bZR0vMOFNPqV-yW2Xs9N42qEwTQ3AY0fDw@mail.gmail.com>
[not found] ` <52AE271C.4040805@oracle.com>
2013-12-15 22:58 ` [patch 019/154] mm: make madvise(MADV_WILLNEED) support swap file prefetch Linus Torvalds
2013-12-16 12:47 ` Kirill A. Shutemov
2013-12-16 15:18 ` Sasha Levin [this message]
2013-12-16 20:52 ` Andrea Arcangeli
2013-12-17 0:18 ` Sasha Levin
2013-12-17 12:44 ` Kirill A. Shutemov
2013-12-17 14:09 ` Sasha Levin
2013-12-20 13:10 ` Kirill A. Shutemov
2013-12-20 13:31 ` Kirill A. Shutemov
2013-12-20 13:36 ` Kirill A. Shutemov
2013-12-20 17:42 ` Andrea Arcangeli
2013-12-23 10:25 ` Mel Gorman
2013-12-23 10:54 ` Kirill A. Shutemov
2013-12-23 11:15 ` Kirill A. Shutemov
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=52AF19CF.2060102@oracle.com \
--to=sasha.levin@oracle.com \
--cc=aarcange@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=hughd@google.com \
--cc=kirill.shutemov@linux.intel.com \
--cc=linux-mm@kvack.org \
--cc=riel@redhat.com \
--cc=shli@fusionio.com \
--cc=shli@kernel.org \
--cc=torvalds@linux-foundation.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.