Commit 91629e6d authored by David Sterba's avatar David Sterba

btrfs: rename macro local variables that clash with other variables

Fix variable names in two macros where there's a local function variable
of the same name.  In subpage_calc_start_bit() it's in several callers,
in btrfs_abort_transaction() it's only in replace_file_extents().
Found by 'make W=2'.
Reviewed-by: default avatarBoris Burkov <boris@bur.io>
Reviewed-by: default avatarAnand Jain <anand.jain@oracle.com>
Reviewed-by: default avatarNaohiro Aota <naohiro.aota@wdc.com>
Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
parent 9c5e1fb0
...@@ -242,12 +242,12 @@ static void btrfs_subpage_assert(const struct btrfs_fs_info *fs_info, ...@@ -242,12 +242,12 @@ static void btrfs_subpage_assert(const struct btrfs_fs_info *fs_info,
#define subpage_calc_start_bit(fs_info, folio, name, start, len) \ #define subpage_calc_start_bit(fs_info, folio, name, start, len) \
({ \ ({ \
unsigned int start_bit; \ unsigned int __start_bit; \
\ \
btrfs_subpage_assert(fs_info, folio, start, len); \ btrfs_subpage_assert(fs_info, folio, start, len); \
start_bit = offset_in_page(start) >> fs_info->sectorsize_bits; \ __start_bit = offset_in_page(start) >> fs_info->sectorsize_bits; \
start_bit += fs_info->subpage_info->name##_offset; \ __start_bit += fs_info->subpage_info->name##_offset; \
start_bit; \ __start_bit; \
}) })
void btrfs_subpage_start_reader(const struct btrfs_fs_info *fs_info, void btrfs_subpage_start_reader(const struct btrfs_fs_info *fs_info,
......
...@@ -229,11 +229,11 @@ bool __cold abort_should_print_stack(int error); ...@@ -229,11 +229,11 @@ bool __cold abort_should_print_stack(int error);
*/ */
#define btrfs_abort_transaction(trans, error) \ #define btrfs_abort_transaction(trans, error) \
do { \ do { \
bool first = false; \ bool __first = false; \
/* Report first abort since mount */ \ /* Report first abort since mount */ \
if (!test_and_set_bit(BTRFS_FS_STATE_TRANS_ABORTED, \ if (!test_and_set_bit(BTRFS_FS_STATE_TRANS_ABORTED, \
&((trans)->fs_info->fs_state))) { \ &((trans)->fs_info->fs_state))) { \
first = true; \ __first = true; \
if (WARN(abort_should_print_stack(error), \ if (WARN(abort_should_print_stack(error), \
KERN_ERR \ KERN_ERR \
"BTRFS: Transaction aborted (error %d)\n", \ "BTRFS: Transaction aborted (error %d)\n", \
...@@ -246,7 +246,7 @@ do { \ ...@@ -246,7 +246,7 @@ do { \
} \ } \
} \ } \
__btrfs_abort_transaction((trans), __func__, \ __btrfs_abort_transaction((trans), __func__, \
__LINE__, (error), first); \ __LINE__, (error), __first); \
} while (0) } while (0)
int btrfs_end_transaction(struct btrfs_trans_handle *trans); int btrfs_end_transaction(struct btrfs_trans_handle *trans);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment