/DragonOS/kernel/src/driver/base/ |
H A D | kset.rs | 92 return KObjectManager::add_kobj(self.self_ref.upgrade().unwrap(), join_kset); in register() 99 KObjectManager::remove_kobj(self.self_ref.upgrade().unwrap()); in unregister() 111 kobj.set_kset(self.self_ref.upgrade()); in join() 118 kobjects.retain(|x| x.upgrade().is_some()); in leave() 120 if let Some(x) = x.upgrade() { in leave() 127 let x = x.upgrade().unwrap(); in leave() 137 kobjects.retain(|x| x.upgrade().is_some()); in cleanup_weak() 141 return self.self_ref.upgrade().unwrap(); in as_kobject()
|
/DragonOS/kernel/src/driver/base/device/ |
H A D | dd.rs | 93 .and_then(|bus| bus.upgrade()) in do_device_attach() 152 if let Some(bus) = driver.bus().and_then(|bus| bus.upgrade()) { in do_device_attach_driver() 211 } else if let Some(bus) = dev.bus().and_then(|bus| bus.upgrade()) { in device_bind_driver() 291 .and_then(|bus| bus.upgrade()) in driver_attach() 331 .and_then(|bus| bus.upgrade()) in match_device() 386 if let Some(bus) = device.bus().and_then(|bus| bus.upgrade()) { in really_probe() 469 if let Some(bus) = device.bus().and_then(|bus| bus.upgrade()) { in add_to_sysfs() 514 .and_then(|bus| bus.upgrade()) in call_driver_probe() 565 if let Some(bus) = device.bus().and_then(|bus| bus.upgrade()) { in driver_bound()
|
H A D | bus.rs | 266 let bus = dev.bus().and_then(|bus| bus.upgrade()); in add_device() 298 .and_then(|bus| bus.upgrade()) in add_driver() 453 let bus = dev.bus().and_then(|bus| bus.upgrade()); in probe_device() 500 .map(|bus| bus.upgrade().unwrap().need_parent_lock()) in rescan_devices_helper() 764 .and_then(|bus| bus.upgrade()) in store() 813 .and_then(|bus| bus.upgrade()) in store()
|
/DragonOS/kernel/src/filesystem/kernfs/ |
H A D | mod.rs | 165 KernCallbackData::new(self.self_ref.upgrade().unwrap(), self.private_data.lock()); in open() 234 return Ok(self.self_ref.upgrade().ok_or(SystemError::ENOENT)?); in find() 242 .upgrade() in find() 298 return self.fs.read().upgrade().unwrap(); in fs() 354 KernCallbackData::new(self.self_ref.upgrade().unwrap(), self.private_data.lock()); in read_at() 378 KernCallbackData::new(self.self_ref.upgrade().unwrap(), self.private_data.lock()); in write_at() 423 .upgrade() in new() 536 Some(self.self_ref.upgrade().unwrap()), in inner_create() 614 return self.inner.read().parent.upgrade(); in parent() 623 return self.inner.read().symlink_target.as_ref()?.upgrade(); in symlink_target()
|
/DragonOS/kernel/src/filesystem/sysfs/ |
H A D | dir.rs | 37 self.kobj.upgrade() in kobj() 61 .map(|p| p.upgrade().unwrap().inode()) in create_dir()
|
H A D | file.rs | 63 let kobj = self.kobj.upgrade().expect("kobj is None"); in callback_read() 76 let kobj = self.kobj.upgrade().expect("kobj is None"); in callback_read() 86 let kobj = self.kobj.upgrade().expect("kobj is None"); in callback_write() 90 let kobj = self.kobj.upgrade().expect("kobj is None"); in callback_write()
|
/DragonOS/kernel/src/driver/tty/ |
H A D | tty_port.rs | 48 self.internal_tty.upgrade() in internal_tty() 52 self.tty.upgrade() in tty()
|
/DragonOS/docs/kernel/locking/ |
H A D | rwlock.md | 120 pub fn upgrade(mut self) -> RwLockWriteGuard<'rwlock, T> 174 "Upgrader1 before upgrade: the value is {value} 177 let mut upgraded_guard = guard.upgrade(); 182 "Upgrader1 after upgrade: the value is {temp}
|
/DragonOS/kernel/src/filesystem/vfs/ |
H A D | mount.rs | 98 mount_fs: self.self_ref.upgrade().unwrap(), in mountpoint_root_inode() 108 self.self_ref.upgrade().unwrap() in self_ref() 163 return self.self_ref.upgrade().unwrap(); in overlaid_inode() 192 return Ok(self.self_ref.upgrade().unwrap()); in do_parent() 221 let mut current = self.self_ref.upgrade().unwrap(); in do_absolute_path() 385 .upgrade() in find() 450 let new_mount_fs = MountFS::new(to_mount_fs, Some(self.self_ref.upgrade().unwrap())); in mount()
|
/DragonOS/kernel/src/driver/rtc/ |
H A D | interface.rs | 14 .and_then(|p| p.upgrade()) in rtc_read_time()
|
H A D | sysfs.rs | 145 .and_then(|x| x.upgrade()) in class() 152 .and_then(|x| x.upgrade()) in driver() 307 .and_then(|x| x.upgrade()) in show()
|
/DragonOS/kernel/src/filesystem/fat/ |
H A D | fs.rs | 140 self.metadata.size = d.size(&self.fs.upgrade().unwrap().clone()) as i64; in update_metadata() 160 d.find_entry(name, None, None, self.fs.upgrade().unwrap())?; in find() 165 self.fs.upgrade().unwrap(), in find() 1400 &guard.fs.upgrade().unwrap(), in read_at() 1425 let fs: &Arc<FATFileSystem> = &guard.fs.upgrade().unwrap(); in write_at() 1451 let fs: &Arc<FATFileSystem> = &guard.fs.upgrade().unwrap(); in create() 1478 return self.0.lock().fs.upgrade().unwrap(); in fs() 1500 let fs: &Arc<FATFileSystem> = &guard.fs.upgrade().unwrap(); in resize() 1562 let dir_iter: FATDirIter = dir.to_iter(guard.fs.upgrade().unwrap()); in list() 1578 guard.fs.upgrade().unwrap(), in list() [all …]
|
/DragonOS/tools/debugging/logmonitor/src/backend/monitor/ |
H A D | mm.rs | 191 let sender = self.mm_log_monitor.upgrade().unwrap().mm_log_sender.clone(); in process_logs() 265 .upgrade() in mm_log_channel_symbol() 274 .upgrade() in should_stop()
|
/DragonOS/kernel/src/driver/base/block/ |
H A D | gendisk.rs | 29 let bsizelog2 = bdev.upgrade().unwrap().blk_size_log2(); in new() 40 return self.bdev.upgrade().unwrap(); in block_device()
|
H A D | disk_info.rs | 51 return self.disk.as_ref().unwrap().upgrade().unwrap(); in disk()
|
/DragonOS/kernel/src/driver/open_firmware/ |
H A D | device_node.rs | 70 self.inner.lock().parent.upgrade() in parent() 86 self.inner.lock().sibling.as_ref().and_then(|s| s.upgrade()) in sibling()
|
/DragonOS/kernel/src/driver/input/serio/i8042/ |
H A D | i8042_ports.rs | 79 let r = guard.device_common.class.clone()?.upgrade(); in class() 87 self.inner().device_common.driver.clone()?.upgrade() in driver()
|
H A D | i8042_device.rs | 78 let r = guard.device_common.class.clone()?.upgrade(); in class() 90 self.inner().device_common.driver.clone()?.upgrade() in driver()
|
/DragonOS/kernel/src/driver/video/fbdev/base/ |
H A D | fbmem.rs | 243 self.inner.lock().fb.upgrade() in framebuffer() 414 let fb = self.inner.lock().fb.upgrade().unwrap(); in read_at() 425 let fb = self.inner.lock().fb.upgrade().unwrap(); in write_at() 435 .upgrade() in fs()
|
/DragonOS/kernel/src/time/ |
H A D | timer.rs | 148 inner_guard.self_ref.upgrade().unwrap(), in activate() 158 let self_arc = inner_guard.self_ref.upgrade().unwrap(); in activate() 197 let this_arc = self.inner().self_ref.upgrade().unwrap(); in cancel()
|
/DragonOS/kernel/src/filesystem/devfs/ |
H A D | mod.rs | 432 return Ok(inode.self_ref.upgrade().ok_or(SystemError::ENOENT)?); in find() 435 return Ok(inode.parent.upgrade().ok_or(SystemError::ENOENT)?); in find() 449 return self.0.lock().fs.upgrade().unwrap(); in fs() 563 .upgrade() in parent() 564 .unwrap_or(me.self_ref.upgrade().unwrap())) in parent()
|
/DragonOS/kernel/src/driver/pci/test/ |
H A D | pt_device.rs | 112 let r = guard.class.clone()?.upgrade(); in class() 121 self.device_data.read().driver.clone()?.upgrade() in driver()
|
/DragonOS/kernel/src/driver/pci/ |
H A D | raw_device.rs | 120 let r = guard.device_common.class.clone()?.upgrade(); in class() 129 self.inner.read().device_common.driver.clone()?.upgrade() in driver()
|
/DragonOS/kernel/src/filesystem/ramfs/ |
H A D | mod.rs | 264 return self.0.lock().fs.upgrade().unwrap(); in fs() 381 .insert(name, other_locked.self_ref.upgrade().unwrap()); in link() 487 return Ok(inode.self_ref.upgrade().ok_or(SystemError::ENOENT)?); in find() 491 return Ok(inode.parent.upgrade().ok_or(SystemError::ENOENT)?); in find() 641 .upgrade() in parent()
|
/DragonOS/kernel/src/exception/ |
H A D | irqchip.rs | 358 let parent_data = irq_data.parent_data().and_then(|p| p.upgrade()); in irq_chip_ack_parent() 374 data = d.parent_data().and_then(|p| p.upgrade()); in irq_chip_retrigger_hierarchy() 448 let parent_data = dt.parent_data().and_then(|p| p.upgrade()); in __irq_do_set_handler()
|