Home
last modified time | relevance | path

Searched refs:RwLock (Results 1 – 12 of 12) sorted by relevance

/DragonOS-0.1.8/docs/kernel/locking/
Drwlock.md1 # RwLock读写锁
16 …的一致性. 数据会被包裹在一个RwLock的数据结构中, 一切的访问必须通过RwLock的数据结构进行访问和修改. 每个要访问共享数据的会获得一个守卫(guard), 只读进程获得READER(读…
27 #### 2.3.1 RwLock数据结构
29 pub struct RwLock<T> {
46 inner: &'a RwLock<T>,
54 inner: &'a RwLock<T>,
58 #### 2.3.5 RwLock的lock的结构介绍
79 ### 3.1 RwLock的主要API
81 ///功能: 输入需要保护的数据类型data,返回一个新的RwLock类型.
129 static LOCK: RwLock<u32> = RwLock::new(100 as u32);
/DragonOS-0.1.8/kernel/src/libs/
Drwlock.rs35 pub struct RwLock<T> { struct
53 inner: &'a RwLock<T>, argument
61 inner: &'a RwLock<T>,
64 unsafe impl<T: Send> Send for RwLock<T> {} implementation
65 unsafe impl<T: Send + Sync> Sync for RwLock<T> {} implementation
68 impl<T> RwLock<T> { implementation
72 return RwLock { in new()
82 let RwLock { data, .. } = self; in into_inner() localVariable
281 impl<T: Default> Default for RwLock<T> { implementation
288 impl<T> From<T> for RwLock<T> { implementation
[all …]
Dnotifier.rs4 libs::{rwlock::RwLock, spinlock::SpinLock},
137 pub struct BlockingNotifierChain<T>(RwLock<NotifierChain<T>>);
141 Self(RwLock::new(NotifierChain::<T>::new())) in new()
/DragonOS-0.1.8/kernel/src/driver/tty/
Dtty_device.rs14 libs::rwlock::RwLock,
23 …pub static ref TTY_DEVICES: RwLock<BTreeMap<String, Arc<TtyDevice>>> = RwLock::new(BTreeMap::new()…
32 fs: RwLock<Weak<DevFS>>,
34 private_data: RwLock<TtyDevicePrivateData>,
50 fs: RwLock::new(Weak::default()), in new()
269 pub fn new(name: &str) -> RwLock<Self> { in new()
272 return RwLock::new(TtyDevicePrivateData { in new()
Dmod.rs10 use crate::libs::rwlock::RwLock;
60 state: RwLock<TtyCoreState>,
86 let state: RwLock<TtyCoreState> = RwLock::new(TtyCoreState { bits: 0 }); in new()
/DragonOS-0.1.8/kernel/src/net/
Dmod.rs8 use crate::{driver::net::NetDriver, kwarn, libs::rwlock::RwLock, syscall::SystemError};
20 …pub static ref NET_DRIVERS: RwLock<BTreeMap<usize, Arc<dyn NetDriver>>> = RwLock::new(BTreeMap::ne…
/DragonOS-0.1.8/kernel/src/driver/keyboard/
Dps2_keyboard.rs12 libs::{keyboard_parser::TypeOneFSM, rwlock::RwLock, spinlock::SpinLock},
18 pub struct LockedPS2KeyBoardInode(RwLock<PS2KeyBoardInode>, AtomicI32); // self.1 用来记录有多少个文件打开了这个in…
71 RwLock::new(inode), in new()
/DragonOS-0.1.8/kernel/src/exception/
Dsoftirq.rs21 libs::rwlock::RwLock,
102 table: RwLock<[Option<Arc<dyn SoftirqVec>>; MAX_SOFTIRQ_NUM as usize]>,
118 table: RwLock::new(data), in new()
/DragonOS-0.1.8/kernel/src/time/
Dtimekeeping.rs9 libs::rwlock::RwLock,
35 pub struct Timekeeper(RwLock<TimekeeperData>);
149 unsafe { __TIMEKEEPER = Some(Timekeeper(RwLock::new(TimekeeperData::new()))) }; in timekeeper_init()
/DragonOS-0.1.8/kernel/src/mm/
Ducontext.rs23 rwlock::{RwLock, RwLockWriteGuard},
53 inner: RwLock<InnerAddressSpace>,
60 inner: RwLock::new(inner), in new()
84 type Target = RwLock<InnerAddressSpace>;
/DragonOS-0.1.8/docs/community/ChangeLog/V0.1.x/
DV0.1.5.md44 - RwLock: new: 新增了rust实现的读写锁 (#186)
/DragonOS-0.1.8/kernel/src/driver/pci/
Dpci.rs7 use crate::libs::rwlock::{RwLock, RwLockReadGuard, RwLockWriteGuard};
72 list: RwLock<LinkedList<Box<dyn PciDeviceStructure>>>,
79 list: RwLock::new(LinkedList::new()), in new()