mirror of
https://github.com/DragonOS-Community/DragonOS.git
synced 2025-06-18 08:06:32 +00:00
删除文件夹时回收dentry缓存
This commit is contained in:
@ -1,5 +1,7 @@
|
||||
#include "chardev.h"
|
||||
#include "internal.h"
|
||||
#include <filesystem/VFS/VFS.h>
|
||||
|
||||
#include <common/mutex.h>
|
||||
#include <common/stdlib.h>
|
||||
#include <common/string.h>
|
||||
@ -55,7 +57,7 @@ int __devfs_chardev_register(struct devfs_private_inode_info_t *private_info, st
|
||||
|
||||
struct vfs_dir_entry_t *dentry = vfs_alloc_dentry(namelen + 1);
|
||||
__devfs_fill_dentry(dentry, devname);
|
||||
__devfs_fill_inode(dentry, __devfs_alloc_inode(), VFS_IF_DEVICE, private_info);
|
||||
__devfs_fill_inode(dentry, vfs_alloc_inode(), VFS_IF_DEVICE, private_info);
|
||||
|
||||
// 将dentry挂载到char文件夹下
|
||||
__devfs_dentry_bind_parent(chardev_folder_dentry, dentry);
|
||||
|
Reference in New Issue
Block a user