• David Hildenbrand's avatar
    kexec: export PG_offline to VMCOREINFO · e04b742f
    David Hildenbrand authored
    Right now, pages inflated as part of a balloon driver will be dumped by
    dump tools like makedumpfile.  While XEN is able to check in the crash
    kernel whether a certain pfn is actuall backed by memory in the
    hypervisor (see xen_oldmem_pfn_is_ram) and optimize this case, dumps of
    other balloon inflated memory will essentially result in zero pages
    getting allocated by the hypervisor and the dump getting filled with
    this data.
    
    The allocation and reading of zero pages can directly be avoided if a
    dumping tool could know which pages only contain stale information not
    to be dumped.
    
    We now have PG_offline which can be (and already is by virtio-balloon)
    used for marking pages as logically offline.  Follow up patches will
    make use of this flag also in other balloon implementations.
    
    Let's export PG_offline via PAGE_OFFLINE_MAPCOUNT_VALUE, so makedumpfile
    can directly skip pages that are logically offline and the content
    therefore stale.
    
    Please note that this is also helpful...
    e04b742f
crash_core.c 11.5 KB