]> git.baikalelectronics.ru Git - kernel.git/commit
coda: convert from atomic_t to refcount_t on coda_vm_ops->refcnt
authorXiyu Yang <xiyuyang19@fudan.edu.cn>
Tue, 9 Nov 2021 02:34:48 +0000 (18:34 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 9 Nov 2021 18:02:51 +0000 (10:02 -0800)
commit8fc3e89315fdcf328c52227e3baccad54af05fd4
tree219168759f7105f1b875d8330a56a20f71a1fbea
parent6596a0b5fe8cfe284b451d833951b38537712267
coda: convert from atomic_t to refcount_t on coda_vm_ops->refcnt

refcount_t type and corresponding API can protect refcounters from
accidental underflow and overflow and further use-after-free situations.

Link: https://lkml.kernel.org/r/20210908140308.18491-8-jaharkes@cs.cmu.edu
Signed-off-by: Xiyu Yang <xiyuyang19@fudan.edu.cn>
Signed-off-by: Xin Tan <tanxin.ctf@gmail.com>
Signed-off-by: Jan Harkes <jaharkes@cs.cmu.edu>
Cc: Alex Shi <alex.shi@linux.alibaba.com>
Cc: Jing Yangyang <jing.yangyang@zte.com.cn>
Cc: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/coda/file.c