• Jeremy Fitzhardinge's avatar
    [PATCH] i386: Make COMPAT_VDSO runtime selectable. · 1dbf527c
    Jeremy Fitzhardinge authored
    Now that relocation of the VDSO for COMPAT_VDSO users is done at
    runtime rather than compile time, it is possible to enable/disable
    compat mode at runtime.
    
    This patch allows you to enable COMPAT_VDSO mode with "vdso=2" on the
    kernel command line, or via sysctl.  (Switching on a running system
    shouldn't be done lightly; any process which was relying on the compat
    VDSO will be upset if it goes away.)
    
    The COMPAT_VDSO config option still exists, but if enabled it just
    makes vdso_enabled default to VDSO_COMPAT.
    
    +From: Hugh Dickins <hugh@veritas.com>
    
    Fix oops from i386-make-compat_vdso-runtime-selectable.patch.
    
    Even mingetty at system startup finds it easy to trigger an oops
    while reading /proc/PID/maps: though it has a good hold on the mm
    itself, that cannot stop exit_mm() from resetting tsk->mm to NULL.
    
    (It is usually show_map()'s call to get_gate_vma() which oopses,
    and I expect we could change that to check priv->tail_vma instead;
    but no matter, even m_start()'s call just after get_task_mm() is racy.)
    Signed-off-by: default avatarJeremy Fitzhardinge <jeremy@xensource.com>
    Signed-off-by: default avatarAndi Kleen <ak@suse.de>
    Cc: Zachary Amsden <zach@vmware.com>
    Cc: "Jan Beulich" <JBeulich@novell.com>
    Cc: Eric W. Biederman <ebiederm@xmission.com>
    Cc: Andi Kleen <ak@suse.de>
    Cc: Ingo Molnar <mingo@elte.hu>
    Cc: Roland McGrath <roland@redhat.com>
    1dbf527c
page.h 4.31 KB