[lkml]   [2008]   [Oct]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCH, RFC] ext4: Replace hackish ext4_mb_poll_new_transaction with commit callback
    On Fri, Oct 17, 2008 at 08:25:52AM -0400, Theodore Tso wrote:
    > On Fri, Oct 17, 2008 at 06:02:14AM -0400, Theodore Tso wrote:
    > > Thanks for reminding me about that; I had completely forgotten about
    > > Andreas' patch. Sure, I'll respin the patch to use his extension.
    > I looked more closely at Andreas' patch, and it's really not a good
    > fit for what we want to do. The problem is that it is designed to
    > attach arbitrary callbacks on a per transaction basis. Each time you
    > add a callback you need to allocate a stucture, and then it gets
    > chained onto a inked list.

    Yeah, I looked at a similar scheme for the buffer commit
    callbacks, and I realized that it would be a total pain. So I went with
    a static callback.

    > What I added was a dead-simple per-journal commit callback, with no
    > additional memory allocations (and requirement to do error handling if
    > the memory allocation fails), no need to take a spinlock before
    > manually adding the call back to each transaction handle, no need to
    > search the linked list to see if we have an entry on the linked list
    > already, etc.

    And this simple callback can used by a jbd2 client to build
    the machinery for per-transaction callbacks if they want.



    "We will have to repent in this generation not merely for the
    vitriolic words and actions of the bad people, but for the
    appalling silence of the good people."
    - Rev. Dr. Martin Luther King, Jr.

    Joel Becker
    Principal Software Developer
    Phone: (650) 506-8127

     \ /
      Last update: 2008-10-17 22:33    [W:0.024 / U:14.140 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site