Home
last modified time | relevance | path

Searched refs:self_ref (Results 1 – 25 of 28) sorted by relevance

12

/DragonOS/kernel/src/filesystem/vfs/
H A Dmount.rs46 self_ref: Weak<MountFS>, field
58 self_ref: Weak<MountFSInode>, field
66 return Arc::new_cyclic(|self_ref| MountFS { in new()
70 self_ref: self_ref.clone(), in new()
88 (*ptr).self_ref = weak; in wrap()
96 return Arc::new_cyclic(|self_ref| MountFSInode { in mountpoint_root_inode()
98 mount_fs: self.self_ref.upgrade().unwrap(), in mountpoint_root_inode()
99 self_ref: self_ref.clone(), in mountpoint_root_inode()
107 pub fn self_ref(&self) -> Arc<Self> { in self_ref() method
108 self.self_ref.upgrade().unwrap() in self_ref()
[all …]
/DragonOS/kernel/src/driver/base/
H A Dkset.rs28 self_ref: Weak<KSet>, field
33 self.self_ref.as_ptr().hash(state); in hash()
42 self.self_ref.as_ptr() == other.self_ref.as_ptr() in eq()
53 self_ref: Weak::default(), in new()
60 (*p).self_ref = Arc::downgrade(&r); in new()
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()
141 return self.self_ref.upgrade().unwrap(); in as_kobject()
/DragonOS/kernel/src/time/
H A Djiffies.rs35 self_ref: Weak<ClocksourceJiffies>, field
49 self.0.lock_irqsave().self_ref.upgrade().unwrap() in clocksource()
90 self_ref: Default::default(), in new()
92 jiffies.0.lock().self_ref = Arc::downgrade(&jiffies); in new()
H A Dtimer.rs124 self_ref: Weak::default(), in new()
129 result.inner.lock().self_ref = Arc::downgrade(&result); in new()
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()
214 self_ref: Weak<Timer>, field
/DragonOS/tools/debugging/logmonitor/src/backend/monitor/
H A Dmm.rs26 self_ref: Weak<Self>, field
58 self_ref: Weak::new(), in new()
65 let self_ref = Arc::downgrade(&r); in new() localVariable
67 (*r_ptr).self_ref = self_ref; in new()
122 let monitor_weak = self.self_ref.clone(); in create_threads()
/DragonOS/kernel/src/filesystem/devfs/
H A Dnull_dev.rs23 self_ref: Weak<LockedNullInode>, field
37 self_ref: Weak::default(), in new()
58 result.0.lock().self_ref = Arc::downgrade(&result); in new()
H A Dzero_dev.rs23 self_ref: Weak<LockedZeroInode>, field
37 self_ref: Weak::default(), in new()
58 result.0.lock().self_ref = Arc::downgrade(&result); in new()
H A Dmod.rs86 root_guard.self_ref = Arc::downgrade(&devfs.root_inode); in new()
247 self_ref: Weak<LockedDevFSInode>, field
271 self_ref: Weak::default(), in new_with_parent()
361 parent: guard.self_ref.clone(), in do_create_with_data()
362 self_ref: Weak::default(), in do_create_with_data()
385 result.0.lock().self_ref = Arc::downgrade(&result); in do_create_with_data()
432 return Ok(inode.self_ref.upgrade().ok_or(SystemError::ENOENT)?); in find()
564 .unwrap_or(me.self_ref.upgrade().unwrap())) in parent()
/DragonOS/kernel/src/driver/input/serio/i8042/
H A Di8042_driver.rs42 self_ref: Weak::new(), in new()
47 r.inner.lock().self_ref = Arc::downgrade(&r); in new()
62 self_ref: Weak<I8042Driver>, field
74 device.set_driver(Some(self.inner.lock().self_ref.clone())); in probe()
/DragonOS/kernel/src/filesystem/kernfs/
H A Dmod.rs78 (*ptr).self_ref = Arc::downgrade(&root_inode); in new()
111 self_ref: Weak::new(), in create_root_inode()
129 self_ref: Weak<KernFSInode>, field
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()
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()
407 self_ref: Weak::new(), in new()
418 (*ptr).self_ref = Arc::downgrade(&inode); in new()
536 Some(self.self_ref.upgrade().unwrap()), in inner_create()
/DragonOS/kernel/src/filesystem/ramfs/
H A Dmod.rs58 self_ref: Weak<LockedRamFSInode>, field
77 self_ref: Weak::default(), in new()
148 root_guard.self_ref = Arc::downgrade(&result.root_inode); in new()
322 parent: inode.self_ref.clone(), in create_with_data()
323 self_ref: Weak::default(), in create_with_data()
348 result.0.lock().self_ref = Arc::downgrade(&result); in create_with_data()
381 .insert(name, other_locked.self_ref.upgrade().unwrap()); in link()
487 return Ok(inode.self_ref.upgrade().ok_or(SystemError::ENOENT)?); in find()
584 parent: inode.self_ref.clone(), in mknod()
585 self_ref: Weak::default(), in mknod()
[all …]
/DragonOS/kernel/src/virt/kvm/
H A Dkvm_dev.rs42 self_ref: Weak<LockedKvmInode>, field
55 self_ref: Weak::default(), in new()
76 result.0.lock().self_ref = Arc::downgrade(&result); in new()
H A Dvcpu_dev.rs52 self_ref: Weak<LockedVcpuInode>, field
66 self_ref: Weak::default(), in new()
90 result.0.lock().self_ref = Arc::downgrade(&result); in new()
H A Dvm_dev.rs50 self_ref: Weak<LockedVmInode>, field
64 self_ref: Weak::default(), in new()
88 result.0.lock().self_ref = Arc::downgrade(&result); in new()
/DragonOS/kernel/src/process/
H A Dkthread.rs137 self_ref: Weak<Self>, field
159 self_ref: Weak::new(), in new()
165 (*tmp).self_ref = Arc::downgrade(&result); in new()
191 let self_ref = self.self_ref.upgrade().unwrap(); in poll_result() localVariable
192 unsafe { Arc::decrement_strong_count(&self_ref) }; in poll_result()
/DragonOS/kernel/src/driver/tty/
H A Dtty_driver.rs88 driver.self_ref.init(Arc::downgrade(&driver)); in tty_register_driver()
139 self_ref: Lazy<Weak<Self>>, field
177 self_ref: Lazy::new(), in new()
213 fn self_ref(&self) -> Arc<Self> { in self_ref() method
214 self.self_ref.get().upgrade().unwrap() in self_ref()
281 let res = tty.install(self.self_ref(), tty.clone()); in driver_install_tty()
313 let tty = TtyCore::new(self.self_ref(), idx); in init_tty_device()
/DragonOS/kernel/src/driver/input/ps2_mouse/
H A Dps_mouse_driver.rs92 self_ref: Weak::new(), in new()
97 r.inner.lock().self_ref = Arc::downgrade(&r); in new()
123 self_ref: Weak<Ps2MouseDriver>, field
245 device.set_driver(Some(self.inner.lock_irqsave().self_ref.clone())); in connect()
/DragonOS/kernel/src/driver/keyboard/
H A Dps2_keyboard.rs67 self_ref: Weak<LockedPS2KeyBoardInode>, field
78 self_ref: Weak::default(), in new()
99 result.0.write().self_ref = Arc::downgrade(&result); in new()
/DragonOS/kernel/src/driver/disk/ahci/
H A Dahcidisk.rs46 self_ref: Weak<LockedAhciDisk>, field
385 let result: Arc<LockedAhciDisk> = Arc::new_cyclic(|self_ref| LockedAhciDisk { in new()
391 self_ref: self_ref.clone(), in new()
405 let disk = self.inner().self_ref.upgrade().unwrap() as Arc<dyn BlockDevice>; in read_mbr_table()
551 return self.inner().self_ref.upgrade().unwrap(); in device()
/DragonOS/kernel/src/driver/block/
H A Dvirtio_blk.rs159 self_ref: Weak<Self>, field
183 let dev = Arc::new_cyclic(|self_ref| Self { in new()
185 self_ref: self_ref.clone(), in new()
275 self.self_ref.upgrade().unwrap() in device()
283 let device = self.self_ref.upgrade().unwrap() as Arc<dyn BlockDevice>; in partitions()
/DragonOS/kernel/src/filesystem/procfs/
H A Dmod.rs117 self_ref: Weak<LockedProcFSInode>, field
327 self_ref: Weak::default(), in new()
362 root_guard.self_ref = Arc::downgrade(&result.root_inode); in new()
614 parent: inode.self_ref.clone(), in create_with_data()
615 self_ref: Weak::default(), in create_with_data()
643 result.0.lock().self_ref = Arc::downgrade(&result); in create_with_data()
675 .insert(name, other_locked.self_ref.upgrade().unwrap()); in link()
724 return Ok(inode.self_ref.upgrade().ok_or(SystemError::ENOENT)?); in find()
/DragonOS/kernel/src/driver/serial/serial8250/
H A Dmod.rs415 self_ref: Weak<Self>, field
424 self_ref: Weak::default(), in new()
429 (*p).self_ref = Arc::downgrade(&r); in new()
452 isa_dev.set_driver(Some(self.self_ref.clone())); in probe()
/DragonOS/kernel/src/ipc/
H A Dpipe.rs52 self_ref: Weak<LockedPipeInode>, field
130 self_ref: Weak::default(), in new()
162 guard.self_ref = Arc::downgrade(&result); in new()
/DragonOS/kernel/src/net/event_poll/
H A Dmod.rs51 self_ref: Option<Weak<SpinLock<EventPoll>>>, field
64 self_ref: None, in new()
249 epoll.0.lock_irqsave().self_ref = Some(Arc::downgrade(&epoll.0)); in do_create_epoll()
645 dst_file.remove_epoll(epoll.self_ref.as_ref().unwrap())?; in ep_remove()
/DragonOS/kernel/src/mm/
H A Ducontext.rs1108 r.vma.lock_irqsave().self_ref = Arc::downgrade(&r); in new()
1229 guard.self_ref.upgrade().unwrap(), in extract()
1283 guard.self_ref.upgrade().unwrap(), in extract()
1363 self_ref: Weak<LockedVMA>, field
1402 self_ref: Weak::default(), in new()
1453 self_ref: self.self_ref.clone(), in clone()
1467 self_ref: Weak::default(), in clone_info_only()

12