diff options
author | Mikulas Patocka <mpatocka@redhat.com> | 2021-05-26 10:16:01 -0400 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2021-06-04 12:07:24 -0400 |
commit | db2351eb22e42c5e29ce0caa967a10bb34efabb5 (patch) | |
tree | c004cbea20922b2029087f490a2271a996bbfd17 /drivers/md/dm-raid1.c | |
parent | 6b06dd5a972288d011a49d63eb9f6a5003d2e932 (diff) |
dm kcopyd: avoid useless atomic operations
The functions set_bit and clear_bit are atomic. We don't need
atomicity when making flags for dm-kcopyd. So, change them to direct
manipulation of the flags.
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-raid1.c')
-rw-r--r-- | drivers/md/dm-raid1.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/dm-raid1.c b/drivers/md/dm-raid1.c index b0a82f29a2e4..ebb4810cc3b4 100644 --- a/drivers/md/dm-raid1.c +++ b/drivers/md/dm-raid1.c @@ -364,7 +364,7 @@ static void recover(struct mirror_set *ms, struct dm_region *reg) /* hand to kcopyd */ if (!errors_handled(ms)) - set_bit(DM_KCOPYD_IGNORE_ERROR, &flags); + flags |= BIT(DM_KCOPYD_IGNORE_ERROR); dm_kcopyd_copy(ms->kcopyd_client, &from, ms->nr_mirrors - 1, to, flags, recovery_complete, reg); |