Commit Graph

1 Commits

Author SHA1 Message Date
Dave Young
9a1312a624 kexec/arch/i386: Add support for KASLR memory randomization
Backport upstream kexec-tools commit for correct kaslr page_offset value
commit 9f62cbddddfc93d78d9aafbddf3e1208cb242f7b
Author: Thomas Garnier <thgarnie@google.com>
Date:   Tue Sep 13 15:10:05 2016 +0800

    kexec/arch/i386: Add support for KASLR memory randomization

    Multiple changes were made on KASLR (right now in linux-next). One of
    them is randomizing the virtual address of the physical mapping, vmalloc
    and vmemmap memory sections. It breaks kdump ability to read physical
    memory.

    This change identifies if KASLR memories randomization is used by
    checking if the page_offset_base variable exists. It search for the
    correct PAGE_OFFSET value by looking at the loaded memory section and
    find the lowest aligned on PUD (the randomization level).

    Related commits on linux-next:
     - 0483e1fa6e09d4948272680f691dccb1edb9677f: Base for randomization
     - 021182e52fe01c1f7b126f97fd6ba048dc4234fd: Enable for PAGE_OFFSET

    Signed-off-by: Thomas Garnier <thgarnie@google.com>
    Signed-off-by: Simon Horman <horms@verge.net.au>

Signed-off-by: Dave Young <dyoung@redhat.com>
Acked-by: Baoquan He <bhe@redhat.com>
2016-11-11 14:14:59 +08:00