Allow __free(iput) markings for easier cleanup on inode allocations. Cc: Christian Brauner <brauner@xxxxxxxxxx> Cc: Peter Zijlstra (Intel) <peterz@xxxxxxxxxxxxx> Cc: Alexander Viro <viro@xxxxxxxxxxxxxxxxxx> Cc: linux-fsdevel@xxxxxxxxxxxxxxx Signed-off-by: Kees Cook <keescook@xxxxxxxxxxxx> --- include/linux/fs.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/fs.h b/include/linux/fs.h index 98b7a7a8c42e..7c3eed3dd1bf 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -2459,6 +2459,8 @@ extern int current_umask(void); extern void ihold(struct inode * inode); extern void iput(struct inode *); +DEFINE_FREE(iput, struct inode *, if (_T) iput(_T)) + int inode_update_timestamps(struct inode *inode, int flags); int generic_update_time(struct inode *, int); -- 2.34.1