Re: [PATCH] erofs: initialized fields can only be observed after bit is set

2021-02-10 Thread Chao Yu
On 2021/2/9 21:06, Gao Xiang via Linux-erofs wrote: From: Gao Xiang Currently, although set_bit() & test_bit() pairs are used as a fast- path for initialized configurations. However, these atomic ops are actually relaxed forms. Instead, load-acquire & store-release form is needed to make sure

Re: [PATCH] erofs: initialized fields can only be observed after bit is set

2021-02-10 Thread Gao Xiang
Hi Chao, On Wed, Feb 10, 2021 at 08:09:22PM +0800, Chao Yu wrote: > Hi Xiang, > > On 2021/2/9 21:06, Gao Xiang via Linux-erofs wrote: > > From: Gao Xiang > > > > Currently, although set_bit() & test_bit() pairs are used as a fast- > > path for initialized configurations. However, these atomic

Re: [PATCH] erofs: initialized fields can only be observed after bit is set

2021-02-10 Thread Chao Yu
Hi Xiang, On 2021/2/9 21:06, Gao Xiang via Linux-erofs wrote: From: Gao Xiang Currently, although set_bit() & test_bit() pairs are used as a fast- path for initialized configurations. However, these atomic ops are actually relaxed forms. Instead, load-acquire & store-release form is needed to

[PATCH] erofs: initialized fields can only be observed after bit is set

2021-02-09 Thread Gao Xiang via Linux-erofs
From: Gao Xiang Currently, although set_bit() & test_bit() pairs are used as a fast- path for initialized configurations. However, these atomic ops are actually relaxed forms. Instead, load-acquire & store-release form is needed to make sure uninitialized fields won't be observed in advance here