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
XFS:.
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
separately.
|