From 06707daa963b89af5861f0fb3c78bebfd8c9bef5 Mon Sep 17 00:00:00 2001 From: Jim Huang Date: Mon, 6 May 2024 16:41:35 +0800 Subject: [PATCH] Enable safe inode cleanup This patch facilitates the proper cleanup and removal of the inode itself as well as any associated cached page data. --- inode.c | 1 + 1 file changed, 1 insertion(+) diff --git a/inode.c b/inode.c index 1eb74dd..615e7bf 100644 --- a/inode.c +++ b/inode.c @@ -613,6 +613,7 @@ static int simplefs_unlink(struct inode *dir, struct dentry *dentry) inode->i_ctime.tv_sec = inode->i_mtime.tv_sec = inode->i_atime.tv_sec = 0; #endif + inode_dec_link_count(inode); drop_nlink(inode); mark_inode_dirty(inode);