Home
last modified time | relevance | path

Searched refs:metadata (Results 1 – 13 of 13) sorted by relevance

/DragonOS-0.1.5/kernel/src/filesystem/devfs/
Dnull_dev.rs27 metadata: Metadata, field
39 metadata: Metadata { in new()
83 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
84 return Ok(self.0.lock().metadata.clone()); in metadata()
95 fn set_metadata(&self, metadata: &Metadata) -> Result<(), i32> { in set_metadata()
97 inode.metadata.atime = metadata.atime; in set_metadata()
98 inode.metadata.mtime = metadata.mtime; in set_metadata()
99 inode.metadata.ctime = metadata.ctime; in set_metadata()
100 inode.metadata.mode = metadata.mode; in set_metadata()
101 inode.metadata.uid = metadata.uid; in set_metadata()
[all …]
Dzero_dev.rs27 metadata: Metadata, field
39 metadata: Metadata { in new()
83 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
84 return Ok(self.0.lock().metadata.clone()); in metadata()
95 fn set_metadata(&self, metadata: &Metadata) -> Result<(), i32> { in set_metadata()
97 inode.metadata.atime = metadata.atime; in set_metadata()
98 inode.metadata.mtime = metadata.mtime; in set_metadata()
99 inode.metadata.ctime = metadata.ctime; in set_metadata()
100 inode.metadata.mode = metadata.mode; in set_metadata()
101 inode.metadata.uid = metadata.uid; in set_metadata()
[all …]
Dmod.rs99 match device.metadata().unwrap().file_type { in register_device()
140 match device.metadata().unwrap().file_type { in unregister_device()
193 metadata: Metadata, field
211 metadata: Metadata { in new_with_parent()
277 if guard.metadata.file_type != FileType::Dir { in do_create_with_data()
291 metadata: Metadata { in do_create_with_data()
349 if inode.metadata.file_type != FileType::Dir { in find()
373 if inode.metadata.file_type != FileType::Dir { in get_entry_name()
390 .filter(|k| inode.children.get(*k).unwrap().metadata().unwrap().inode_id == ino) in get_entry_name()
397 …_id={inode_id}, to find={to_find}", key_len=key.len(), inode_id = inode.metadata.inode_id, to_find… in get_entry_name()
[all …]
/DragonOS-0.1.5/kernel/src/driver/disk/ahci/
Dahci_inode.rs29 metadata: Metadata, field
44 metadata: Metadata { in new()
88 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
89 return Ok(self.0.lock().metadata.clone()); in metadata()
100 fn set_metadata(&self, metadata: &Metadata) -> Result<(), i32> { in set_metadata()
102 inode.metadata.atime = metadata.atime; in set_metadata()
103 inode.metadata.mtime = metadata.mtime; in set_metadata()
104 inode.metadata.ctime = metadata.ctime; in set_metadata()
105 inode.metadata.mode = metadata.mode; in set_metadata()
106 inode.metadata.uid = metadata.uid; in set_metadata()
[all …]
/DragonOS-0.1.5/kernel/src/driver/keyboard/
Dps2_keyboard.rs26 metadata: Metadata, field
38 metadata: Metadata { in new()
128 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
129 return Ok(self.0.lock().metadata.clone()); in metadata()
132 fn set_metadata(&self, metadata: &Metadata) -> Result<(), i32> { in set_metadata()
134 inode.metadata.atime = metadata.atime; in set_metadata()
135 inode.metadata.mtime = metadata.mtime; in set_metadata()
136 inode.metadata.ctime = metadata.ctime; in set_metadata()
137 inode.metadata.mode = metadata.mode; in set_metadata()
138 inode.metadata.uid = metadata.uid; in set_metadata()
[all …]
/DragonOS-0.1.5/kernel/src/filesystem/ramfs/
Dmod.rs53 metadata: Metadata, field
85 metadata: Metadata { in new()
133 if inode.metadata.file_type == FileType::Dir { in read_at()
166 if inode.metadata.file_type == FileType::Dir { in write_at()
187 if inode.metadata.file_type == FileType::Dir { in poll()
204 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
206 let mut metadata = inode.metadata.clone(); in metadata() localVariable
207 metadata.size = inode.data.len() as i64; in metadata()
209 return Ok(metadata); in metadata()
212 fn set_metadata(&self, metadata: &Metadata) -> Result<(), i32> { in set_metadata()
[all …]
/DragonOS-0.1.5/kernel/src/filesystem/procfs/
Dmod.rs98 metadata: Metadata, field
243 metadata: Metadata { in new()
327 if let FileType::Dir = inode.metadata.file_type { in open()
340 inode.metadata.size = file_size; in open()
348 if let FileType::Dir = guard.metadata.file_type { in close()
377 if inode.metadata.file_type == FileType::Dir { in read_at()
425 if inode.metadata.file_type == FileType::Dir { in poll()
442 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
444 let metadata = inode.metadata.clone(); in metadata() localVariable
446 return Ok(metadata); in metadata()
[all …]
/DragonOS-0.1.5/kernel/src/filesystem/vfs/
Dmount.rs108 return Ok(self.inner_inode.fs().root_inode().metadata()?.inode_id in is_mountpoint_root()
109 == self.inner_inode.metadata()?.inode_id); in is_mountpoint_root()
118 let inode_id = self.metadata().unwrap().inode_id; in overlaid_inode()
191 fn metadata(&self) -> Result<super::Metadata, i32> { in metadata() method
192 return self.inner_inode.metadata(); in metadata()
196 fn set_metadata(&self, metadata: &super::Metadata) -> Result<(), i32> { in set_metadata()
197 return self.inner_inode.set_metadata(metadata); in set_metadata()
227 let inode_id = self.inner_inode.find(name)?.metadata()?.inode_id; in unlink()
239 let inode_id = self.inner_inode.find(name)?.metadata()?.inode_id; in rmdir()
329 let metadata = self.inner_inode.metadata()?; in mount() localVariable
[all …]
Dfile.rs100 let file_type: FileType = inode.metadata()?.file_type; in new()
157 pub fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
158 return self.inode.metadata(); in metadata()
170 if self.inode.metadata().unwrap().file_type == FileType::Pipe { in lseek()
182 let metadata = self.metadata()?; in lseek() localVariable
183 pos = metadata.size + offset; in lseek()
190 if pos < 0 || pos > self.metadata()?.size { in lseek()
247 dirent.d_ino = sub_inode.metadata().unwrap().inode_id as u64; in readdir()
250 dirent.d_type = sub_inode.metadata().unwrap().file_type.get_file_type_num() as u8; in readdir()
Dmod.rs151 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
297 return Ok((name, entry.metadata()?)); in get_entry_name_and_metadata()
365 if self.metadata()?.file_type != FileType::Dir { in lookup_follow_symlink()
382 if result.metadata()?.file_type != FileType::Dir { in lookup_follow_symlink()
410 if inode.metadata()?.file_type == FileType::SymLink && max_follow_times > 0 { in lookup_follow_symlink()
Dcore.rs217 let file_type: FileType = inode.metadata()?.file_type; in do_open()
343 if parent_inode.metadata()?.file_type != FileType::Dir { in do_remove_dir()
348 if target_inode.metadata()?.file_type != FileType::Dir { in do_remove_dir()
375 if inode.unwrap().metadata()?.file_type == FileType::Dir { in do_unlink_at()
383 if parent_inode.metadata()?.file_type != FileType::Dir { in do_unlink_at()
Dsyscall.rs205 match inode.metadata() { in sys_chdir()
/DragonOS-0.1.5/kernel/src/filesystem/fat/
Dfs.rs99 metadata: Metadata, field
113 self.metadata.size = f.size() as i64; in update_metadata()
116 self.metadata.size = d.size(&self.fs.upgrade().unwrap().clone()) as i64; in update_metadata()
179 metadata: Metadata { in new()
291 metadata: Metadata { in new()
1404 if inode.metadata.file_type == FileType::Dir { in poll()
1456 fn metadata(&self) -> Result<Metadata, i32> { in metadata() method
1457 return Ok(self.0.lock().metadata.clone()); in metadata()
1583 if guard.metadata.file_type != FileType::Dir { in get_entry_name()
1599 .filter(|k| guard.children.get(*k).unwrap().metadata().unwrap().inode_id == ino) in get_entry_name()
[all …]