On 2 May 2012 22:01, Jeff Mahoney <je...@suse.com> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 05/02/2012 01:44 AM, Daniel J Blueman wrote:
>> I see the filesystem going readonly when run_clustered_refs
>> returns -ENOSPC [1], so it looks like we need something like:
>>
>> --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c @@
>> -2451,7 +2451,8 @@ again: ret = run_clustered_refs(trans, root,
>> &cluster); if (ret < 0) { spin_unlock(&delayed_refs->lock); -
>> btrfs_abort_transaction(trans, root, ret); +
>> if (ret != -ENOSPC) +
>> btrfs_abort_transaction(trans, root, ret); return ret; }
>>
>> No?
>
> No. In most cases ENOSPC is indistinguishable from any other error. An
> ENOSPC in deep code means that the reservation for the transaction
> wasn't big enough.

Ahh, makes sense. When I get some time, I'll dump the transaction
state and check how the reservation code calculates the length...

Thanks,
  Daniel
-- 
Daniel J Blueman
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to