[lkml]   [2012]   [Feb]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCHSET] mempool, percpu, blkcg: fix percpu stat allocation and remove stats_lock
    On Sun, Feb 26, 2012 at 06:44:21AM +0900, Tejun Heo wrote:
    > Hello, Vivek.
    > On Fri, Feb 24, 2012 at 09:20:33AM -0500, Vivek Goyal wrote:
    > > Ok. I will write a patch. Things have changed a lot since last time.
    > > I think there is only one tricky part and that is waiting for any
    > > scheduled work to finish during blkg destruction. Because group destruction
    > > happens under both queue and blkcg spin locks, I think I will have to take
    > > the group off list, drop locks, wait for worker thread to finish and then
    > > take locks again and walk through list again to kill remaining groups.
    > Rather than embedding work_struct into blkg and tying work and blkg
    > destruction, why not just create a spinlock protected alloc-pending
    > list? On blkg creation, link blkg onto that list and kick shared work
    > item and on destruction, just unlink it. Worker function can walk the
    > list and try to alloc for all and reschedule if alloc fails.

    Ok. This sounds better than embeding work_struct in blkg, I can embed it
    in request_queue and make the worker walk the list of blkg pending
    alloc of stats. Will try that. Thanks for the idea.


     \ /
      Last update: 2012-02-27 04:15    [W:0.019 / U:6.784 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site