Re: [PATCH 1/2] ext4: fix race when setting the bitmap corrupted flag again

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2018/12/18 22:25, Wang Shilong Wrote:
> Hi,
> 
> 在 2018/12/18 下午7:57,“zhangyi (F)”<yi.zhang@xxxxxxxxxx> 写入:
> 
>     Commit 9af0b3d12577 "ext4: fix race when setting the bitmap corrupted
>     flag" want to fix race between setting inode/block bitmap corrupted
>     flag and reducing free group inodes/clusters counter to prevent
>     multiple frees. But ext4_test_and_set_bit() will invoke
>     __test_and_set_bit() which is non-atomic, so the race is still there.
>     Fix this by invoke test_and_set_bit() instead.
>    
>     Fixes: 9af0b3d12577 ("ext4: fix race when setting the bitmap corrupted flag")
>     Signed-off-by: zhangyi (F) <yi.zhang@xxxxxxxxxx>
> 
> Thanks for fixing this!, I was not aware of __test_and_set_bit() is not non-atomic operation before.
> 
> Reviewed-by: Wang Shilong <wshilong@xxxxxxx>
> 
> Btw for a stable process question, commit 9af0b3d12577 had CC tag to Stable kernel, should we
> add it again here or with 'Fixes' tag, it will be included automatically?
> 
Thank you for reminding me of the CC stable tag, I missed this tag and I'm not sure it
will be added automatically or not. Anyway, I will add this tag in the next iteration.

Thanks,
Yi.




[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux