lkml.org 
[lkml]   [2009]   [Aug]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    SubjectRe: [patch 3/4 -mm] flex_array: poison free elements
    From
    Date
    On Mon, 2009-08-24 at 13:41 -0700, David Rientjes wrote:
    > LEX_ARRAY_FREE (or an additional poison value to
    > distinguish between use-uninitialized vs. use-after-free) must be used in
    > flex_array_clear() otherwise the cgroup patchset, the only proposed user
    > of this library code, could never shrink this array when pid's are free
    > like the kmalloc vs. vmalloc patchset could do.

    Are you saying that you expected it to never reallocate the array, but
    have a permanent flex_array and that it just calls flex_array_clear() on
    the elements that it doesn't want any more, and the array ends up
    sparsely populated? I can see why we'd need a poison value in that
    case.

    Or, are we just talking about a situation where we need to truncate the
    pidlist?

    -- Dave



    \
     
     \ /
      Last update: 2009-08-24 23:19    [W:0.024 / U:61.624 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site