lkml.org 
[lkml]   [2015]   [Aug]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    SubjectRe: [PATCH 1/2] cgroup: get a ref to source csses when migrating
    From
    > Have you verified that the scenario you're describing can actually
    > happen? AFAICS, cgroup_migrate_add_src() already does the pinning.

    Hmmm. Looking at it, group_migrate_add_src() does grab a ref on the
    css_set which contains the css, and the comments mention that grabbing
    a ref on the css_set will stop the css from being dropped. I must've
    misunderstood one of your previous emails (where you said that such
    code was not safe in the ->can_fork(), ->cancel_fork() and ->fork())
    path.

    You also mentioned that depending on the css_set's ref being bumped to
    protect the contained csses is "sort of implementation detail. It can
    be implemented in different ways." Which made me think that depending
    on that is not a good idea.

    But if it's safe to depend on the cgroup_migrate_add_src() pinning the
    ref on the css_set, I'll drop this patch and fix up the other one
    accordingly.

    --
    Aleksa Sarai (cyphar)
    www.cyphar.com


    \
     
     \ /
      Last update: 2015-08-25 04:21    [W:5.214 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site