xfs
[Top] [All Lists]

Re: [PATCH 1/2] xfs: don't truncate attribute extents if no extents exis

To: Brian Foster <bfoster@xxxxxxxxxx>
Subject: Re: [PATCH 1/2] xfs: don't truncate attribute extents if no extents exist
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Fri, 19 Jun 2015 08:14:21 -0700
Cc: xfs@xxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <1434631741-50856-2-git-send-email-bfoster@xxxxxxxxxx>
References: <1434631741-50856-1-git-send-email-bfoster@xxxxxxxxxx> <1434631741-50856-2-git-send-email-bfoster@xxxxxxxxxx>
User-agent: Mutt/1.5.23 (2014-03-12)
> A '-p 2' fsstress run to ENOSPC on a relatively small fs (1GB)
> reproduces these problems.

Any chance to add this test case to xfstests?

>       /* invalidate and truncate the attribute fork extents */
> -     if (dp->i_d.di_aformat != XFS_DINODE_FMT_LOCAL) {
> +     if (xfs_inode_hasattr(dp) &&
> +         dp->i_d.di_aformat != XFS_DINODE_FMT_LOCAL) {

And please add a comment describing the condition here, especially
as xfs_inode_hasattr doesn't have a very descriptive name.

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