[Top] [All Lists]

Re: [PATCH] XFS: Ensure we force all busy extents in range to disk

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH] XFS: Ensure we force all busy extents in range to disk
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Sat, 2 Jan 2010 06:23:29 -0500
Cc: xfs@xxxxxxxxxxx
In-reply-to: <1262399936-19195-1-git-send-email-david@xxxxxxxxxxxxx>
References: <1262399936-19195-1-git-send-email-david@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.19 (2009-01-05)
Looks good, and quite interestin that we never could it before.

Some nipicks below:

> +     /*
> +      * search pagb_list for this slot, skipping open slots. We have to
> +      * search the entire array as there may be multiple overlaps and
> +      * we have to get the most recent LSN for the log force to push out
> +      * all the transactions that span the range.
> +      */
> +     for (bsy = pag->pagb_list; cnt; bsy++, cnt--) {

Maybe you coult convert this to a more standard loop idiom while you're
at it:

        for (cnt = 0; cnt < pag->pagb_count; cnt++) {
                bsy = &pag->pagb_list[cnt];

> +             if (!bsy->busy_tp)
> +                     continue;
> +             bend = bsy->busy_start + bsy->busy_length - 1;
> +             if ((bno > bend) || (uend < bsy->busy_start))

no need for the inner braces here.

And btw, the standard subsystem prefix is all lower case, xfs:, not

Also it seems like this patch requires your perag-lookup fixes first.
Time to get them into the for-2.6.34 git tree ASAP as a base to work
against.  That might also make it easier to work on the lockless patch

<Prev in Thread] Current Thread [Next in Thread>