mbcache: automatically delete entries from cache on freeing
stable inclusion from stable-v4.19.270 commit 61dc6cdfc85000e305a58553d41036716b427a0d category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I6DPF8 CVE: NA -------------------------------- [ Upstream commit 307af6c8 ] Use the fact that entries with elevated refcount are not removed from the hash and just move removal of the entry from the hash to the entry freeing time. When doing this we also change the generic code to hold one reference to the cache entry, not two of them, which makes code somewhat more obvious. Signed-off-by:Jan Kara <jack@suse.cz> Link: https://lore.kernel.org/r/20220712105436.32204-10-jack@suse.cz Signed-off-by:
Theodore Ts'o <tytso@mit.edu> Stable-dep-of: a44e84a9 ("ext4: fix deadlock due to mbcache entry corruption") Signed-off-by:
Sasha Levin <sashal@kernel.org> Signed-off-by:
Yongqiang Liu <liuyongqiang13@huawei.com>
Loading
Please sign in to comment