lkml.org 
[lkml]   [2011]   [Nov]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    Subject[PATCH 0/4] Checkpoint/Restore: Show in proc IDs of objects that can be shared between tasks
    While doing the checkpoint-restore in the userspace one need to determine
    whether various kernel objects (like mm_struct-s of file_struct-s) are shared
    between tasks and restore this state.

    The 2nd step can for now be solved by using respective CLONE_XXX flags and
    the unshare syscall, while there's currently no ways for solving the 1st one.

    One of the ways for checking whether two tasks share e.g. an mm_struct is to
    provide some mm_struct ID of a task to its proc file. The best from the
    performance point of view ID is the object address in the kernel, but showing
    them to the userspace is not good for performance reasons.

    The previous attempt to solve this was to generate an ID for slab/slub and then
    mix it up with the object index on the slab page. This attempt wasn't met
    warmly by slab maintainers, so here's the 2nd approach.

    The object address is XOR-ed with a "random" value of the same size and then
    shown in proc. Providing this poison is not leaked into the userspace then
    ID seem to be safe.

    The other change from the previous set - this now includes patches from /proc
    to show the IDs generated. The objects for which the IDs are shown are:

    * all namespaces living in /proc/pid/ns/
    * open files (shown in /proc/pid/fdinfo/)
    * objects, that can be shared with CLONE_XXX flags (except for namespaces)

    Signed-off-by: Pavel Emelyanov <xemul@parallels.com>



    \
     
     \ /
      Last update: 2011-11-15 12:39    [W:6.107 / U:0.700 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site