mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-28 11:53:24 +00:00
Remove Vnode to let the fs use PageCache for itself
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
aeea333945
commit
98bf3d4845
@ -94,7 +94,7 @@ impl FileSystem for DevPts {
|
||||
}
|
||||
|
||||
fn flags(&self) -> FsFlags {
|
||||
FsFlags::NO_PAGECACHE
|
||||
FsFlags::empty()
|
||||
}
|
||||
}
|
||||
|
||||
@ -148,6 +148,16 @@ impl Inode for RootInode {
|
||||
self.metadata.clone()
|
||||
}
|
||||
|
||||
fn type_(&self) -> InodeType {
|
||||
self.metadata.type_
|
||||
}
|
||||
|
||||
fn mode(&self) -> InodeMode {
|
||||
self.metadata.mode
|
||||
}
|
||||
|
||||
fn set_mode(&self, mode: InodeMode) {}
|
||||
|
||||
fn atime(&self) -> Duration {
|
||||
self.metadata.atime
|
||||
}
|
||||
@ -160,8 +170,6 @@ impl Inode for RootInode {
|
||||
|
||||
fn set_mtime(&self, time: Duration) {}
|
||||
|
||||
fn set_mode(&self, mode: InodeMode) {}
|
||||
|
||||
fn create(&self, name: &str, type_: InodeType, mode: InodeMode) -> Result<Arc<dyn Inode>> {
|
||||
Err(Error::new(Errno::EPERM))
|
||||
}
|
||||
|
Reference in New Issue
Block a user