]> exis.tech > repos - linux.git/blobdiff - fs/btrfs/extent_map.c
Merge tag 'hwmon-for-v7.2-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/groec...
[linux.git] / fs / btrfs / extent_map.c
index fce9c5cc012283dddb891c0e45b06180878a6148..6ad7b39ae358b24388f742c50165ff6d04979345 100644 (file)
@@ -866,13 +866,13 @@ void btrfs_drop_extent_map_range(struct btrfs_inode *inode, u64 start, u64 end,
                        goto next;
                }
 
-               flags = em->flags;
                /*
                 * In case we split the extent map, we want to preserve the
                 * EXTENT_FLAG_LOGGING flag on our extent map, but we don't want
                 * it on the new extent maps.
                 */
-               em->flags &= ~(EXTENT_FLAG_PINNED | EXTENT_FLAG_LOGGING);
+               flags = em->flags & ~EXTENT_FLAG_LOGGING;
+               em->flags &= ~EXTENT_FLAG_PINNED;
                modified = !list_empty(&em->list);
 
                /*