exfat: fix erroneous discard when clear cluster bit
stable inclusion from stable-5.10.36 commit 11e3ff7e164a69b8807a9c1066c1b6adbb6033e1 bugzilla: 51867 CVE: NA -------------------------------- commit 77edfc6e upstream. If mounted with discard option, exFAT issues discard command when clear cluster bit to remove file. But the input parameter of cluster-to-sector calculation is abnormally added by reserved cluster size which is 2, leading to discard unrelated sectors included in target+2 cluster. With fixing this, remove the wrong comments in set/clear/find bitmap functions. Fixes: 1e49a94c ("exfat: add bitmap operations") Cc: stable@vger.kernel.org # v5.7+ Signed-off-by: NHyeongseok Kim <hyeongseok@gmail.com> Acked-by: NSungjong Seo <sj1557.seo@samsung.com> Signed-off-by: NNamjae Jeon <namjae.jeon@samsung.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: NChen Jun <chenjun102@huawei.com> Acked-by: NWeilong Chen <chenweilong@huawei.com> Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Showing
想要评论请 注册 或 登录