Re: ktime_get_ts64() splat during resume

From
chenyu <hidden>
Date
2016-06-20 08:17:21
Also in
linux-pm, lkml
Reply to
Rafael J. Wysocki, 2016-06-17
On Fri, Jun 17, 2016 at 11:28 PM, Rafael J. Wysocki [off-list ref] wrote:
On Fri, Jun 17, 2016 at 4:33 PM, Borislav Petkov [off-list ref] wrote:
quoted
Ok,

bisect is done, full log below.

Rafael, that fix

  70595b479ce1 ("x86/power/64: Fix crash whan the hibernation code passes control to the image kernel")

breaks s2disk here. It explodes during resume and a statically allocated
struct's member is NULL. See

https://lkml.kernel.org/r/20160617105435.GB15997@pd.tnic (local)

for the splat and some debugging attempts.

Reverting 70595b479ce1 fixes the issue here.
Quite evidently, memory is corrupted in the image kernel, but this
particular commit only affects the boot kernel, so it can't really
corrupt anything in the image one.
In previous patch,
before we jump to the new kernel entry, we add the
text mapping to temp_level4_pgt,

         /* switch over to the temporary kernel text mapping */
        movq    %r8, (%r9)
If I understand correctly,  r9 contains the virtual address
of restore_pgd_addr, since the page table for restore_pgd_addr might be
incoherent across hibernation(as NX patch changes the kernel text mapping
to dynamically mapping), so we might write pmd entry to an incorrect place in
temp_level4_pgt?

Yu
Thread (16 messages) 16 messages, 7 authors, last reply 2016-06-21
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help