]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs: use correct state defines in xfs_bmap_del_extent_{cow,delay}
authorChristoph Hellwig <hch@lst.de>
Fri, 17 Nov 2017 04:11:30 +0000 (22:11 -0600)
committerEric Sandeen <sandeen@redhat.com>
Fri, 17 Nov 2017 04:11:30 +0000 (22:11 -0600)
Source kernel commit: 0173c689ff4c0855e24ceb898274af1339b5db48

Use the _FILLING values to match the usage in the xfs_bmap_add_extent_*
helpers.  No change in behavior, just better naming in the code and
tracepoint output.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reported-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/xfs_bmap.c

index 4aa12931e227ff53363393332df94c2b92fc6349..84bd1981b8dd75b18c887570469f1f1d5da7b8f8 100644 (file)
@@ -4886,19 +4886,19 @@ xfs_bmap_del_extent_delay(
                state |= BMAP_COWFORK;
 
        if (got->br_startoff == del->br_startoff)
-               state |= BMAP_LEFT_CONTIG;
+               state |= BMAP_LEFT_FILLING;
        if (got_endoff == del_endoff)
-               state |= BMAP_RIGHT_CONTIG;
+               state |= BMAP_RIGHT_FILLING;
 
-       switch (state & (BMAP_LEFT_CONTIG | BMAP_RIGHT_CONTIG)) {
-       case BMAP_LEFT_CONTIG | BMAP_RIGHT_CONTIG:
+       switch (state & (BMAP_LEFT_FILLING | BMAP_RIGHT_FILLING)) {
+       case BMAP_LEFT_FILLING | BMAP_RIGHT_FILLING:
                /*
                 * Matches the whole extent.  Delete the entry.
                 */
                xfs_iext_remove(ip, *idx, 1, state);
                --*idx;
                break;
-       case BMAP_LEFT_CONTIG:
+       case BMAP_LEFT_FILLING:
                /*
                 * Deleting the first part of the extent.
                 */
@@ -4911,7 +4911,7 @@ xfs_bmap_del_extent_delay(
                xfs_iext_update_extent(ifp, *idx, got);
                trace_xfs_bmap_post_update(ip, *idx, state, _THIS_IP_);
                break;
-       case BMAP_RIGHT_CONTIG:
+       case BMAP_RIGHT_FILLING:
                /*
                 * Deleting the last part of the extent.
                 */
@@ -4996,19 +4996,19 @@ xfs_bmap_del_extent_cow(
        ASSERT(!isnullstartblock(got->br_startblock));
 
        if (got->br_startoff == del->br_startoff)
-               state |= BMAP_LEFT_CONTIG;
+               state |= BMAP_LEFT_FILLING;
        if (got_endoff == del_endoff)
-               state |= BMAP_RIGHT_CONTIG;
+               state |= BMAP_RIGHT_FILLING;
 
-       switch (state & (BMAP_LEFT_CONTIG | BMAP_RIGHT_CONTIG)) {
-       case BMAP_LEFT_CONTIG | BMAP_RIGHT_CONTIG:
+       switch (state & (BMAP_LEFT_FILLING | BMAP_RIGHT_FILLING)) {
+       case BMAP_LEFT_FILLING | BMAP_RIGHT_FILLING:
                /*
                 * Matches the whole extent.  Delete the entry.
                 */
                xfs_iext_remove(ip, *idx, 1, state);
                --*idx;
                break;
-       case BMAP_LEFT_CONTIG:
+       case BMAP_LEFT_FILLING:
                /*
                 * Deleting the first part of the extent.
                 */
@@ -5019,7 +5019,7 @@ xfs_bmap_del_extent_cow(
                xfs_iext_update_extent(ifp, *idx, got);
                trace_xfs_bmap_post_update(ip, *idx, state, _THIS_IP_);
                break;
-       case BMAP_RIGHT_CONTIG:
+       case BMAP_RIGHT_FILLING:
                /*
                 * Deleting the last part of the extent.
                 */