diff options
author | 2024-02-02 13:23:28 +0900 | |
---|---|---|
committer | 2024-03-04 16:24:47 +0100 | |
commit | 4dc4a3be6cc4ef0a04785124afb0bd4fd06298ff (patch) | |
tree | 025f6217aab3402a67451979fb1d9466d0a873d8 /fs/btrfs/defrag.c | |
parent | btrfs: preallocate temporary extent buffer for inode logging when needed (diff) | |
download | wireguard-linux-4dc4a3be6cc4ef0a04785124afb0bd4fd06298ff.tar.xz wireguard-linux-4dc4a3be6cc4ef0a04785124afb0bd4fd06298ff.zip |
btrfs: use READ/WRITE_ONCE for fs_devices->read_policy
Since we can read/modify the value from the sysfs interface concurrently,
it would be better to protect it from compiler optimizations.
Currently, there is only one read policy BTRFS_READ_POLICY_PID available,
so no actual problem can happen now. This is a preparation for the future
expansion.
Reviewed-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/defrag.c')
0 files changed, 0 insertions, 0 deletions