md: use READ_ONCE/WRITE_ONCE for 'suspend_lo' and 'suspend_hi'
authorYu Kuai <yukuai3@huawei.com>
Tue, 10 Oct 2023 15:19:40 +0000 (23:19 +0800)
committerSong Liu <song@kernel.org>
Wed, 11 Oct 2023 01:49:49 +0000 (18:49 -0700)
commit617787f1386da5e851dad68926a31522134d352b
tree51f926ec5ca0fa5cae444390d5c5ffe47938ea63
parent9e55a22fce1384837c213274d1a3b93be16ed9d7
md: use READ_ONCE/WRITE_ONCE for 'suspend_lo' and 'suspend_hi'

Protect 'suspend_lo' and 'suspend_hi' with READ_ONCE/WRITE_ONCE to prevent
reading abnormal values.

Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Signed-off-by: Song Liu <song@kernel.org>
Link: https://lore.kernel.org/r/20231010151958.145896-2-yukuai1@huaweicloud.com
drivers/md/md.c