Home
last modified time | relevance | path

Searched refs:as_mut (Results 1 – 25 of 38) sorted by relevance

12

/DragonOS/kernel/src/driver/net/
H A Ddma.rs31 let kernel_mapper = kernel_mapper.as_mut().unwrap(); in dma_alloc()
53 let kernel_mapper = kernel_mapper.as_mut().unwrap(); in dma_dealloc()
/DragonOS/kernel/src/mm/
H A Dpercpu.rs95 &mut (self as *const Self as *mut Self).as_mut().unwrap().inner[cpu_id.data() as usize] in get_mut()
105 &mut (self as *const Self as *mut Self).as_mut().unwrap().inner[cpu_id.data() as usize] in force_get_mut()
H A Dkernel_mapper.rs74 pub fn as_mut(&mut self) -> Option<&mut PageMapper> { in as_mut() method
H A Dmmio_buddy.rs545 let mut kernel_mapper = bindings.as_mut(); in release_mmio()
558 .as_mut() in release_mmio()
/DragonOS/kernel/src/driver/disk/ahci/
H A Dmod.rs72 let hba_mem = unsafe { (virtaddr.data() as *mut HbaMem).as_mut().unwrap() }; in ahci_init()
73 hba_mem_list.push(unsafe { (virtaddr.data() as *mut HbaMem).as_mut().unwrap() }); in ahci_init()
142 return unsafe { (port as *const HbaPort as *mut HbaPort).as_mut().unwrap() }; in _port()
H A Dahcidisk.rs103 .as_mut() in read_at()
127 buf_ptr = kbuf.as_mut().unwrap().as_mut_ptr() as usize; in read_at()
135 .as_mut() in read_at()
171 .as_mut() in read_at()
260 .as_mut() in write_at()
291 buf_ptr = kbuf.as_mut().unwrap().as_mut_ptr() as usize; in write_at()
299 .as_mut() in write_at()
338 .as_mut() in write_at()
/DragonOS/kernel/src/driver/virtio/
H A Dvirtio_impl.rs38 let kernel_mapper = kernel_mapper.as_mut().unwrap(); in dma_alloc()
64 let kernel_mapper = kernel_mapper.as_mut().unwrap(); in dma_dealloc()
/DragonOS/kernel/src/arch/riscv64/mm/
H A Dinit.rs144 let mut allocator_guard = binding.as_mut().unwrap(); in riscv_mm_init()
203 assert!(mapper.as_mut().is_some()); in unmap_at_low_address()
212 .as_mut() in unmap_at_low_address()
/DragonOS/kernel/src/libs/
H A Dlock_free_flags.rs26 .as_mut() in get_mut()
/DragonOS/kernel/src/arch/x86_64/process/
H A Dmod.rs151 self.fp_state.as_mut().unwrap().save(); in save_fp_state()
159 self.fp_state.as_mut().unwrap().restore(); in restore_fp_state()
174 self.fp_state.as_mut().unwrap().clear(); in clear_fp_state()
407 PROCESS_SWITCH_RESULT.as_mut().unwrap().get_mut().prev_pcb = Some(prev); in switch_process()
408 PROCESS_SWITCH_RESULT.as_mut().unwrap().get_mut().next_pcb = Some(next); in switch_process()
/DragonOS/kernel/src/exception/
H A Dsoftirq.rs44 let cpu_pending = __CPU_PENDING.as_mut().unwrap(); in softirq_init()
56 return __SORTIRQ_VECTORS.as_mut().unwrap(); in softirq_vectors()
63 return &mut __CPU_PENDING.as_mut().unwrap()[cpu_id.data() as usize]; in cpu_pending()
/DragonOS/kernel/src/arch/x86_64/driver/apic/
H A Dmod.rs457 if let Some(xapic) = current_xapic_instance().borrow_mut().as_mut() { in write_xapic_register()
513 if let Some(xapic) = cur.as_mut() { in init_current_cpu()
583 } else if let Some(xapic) = current_xapic_instance().borrow_mut().as_mut() { in set_lvt()
603 } else if let Some(xapic) = current_xapic_instance().borrow_mut().as_mut() { in mask_all_lvt()
/DragonOS/kernel/src/arch/riscv64/process/
H A Dmod.rs194 PROCESS_SWITCH_RESULT.as_mut().unwrap().get_mut().prev_pcb = Some(prev); in switch_process()
195 PROCESS_SWITCH_RESULT.as_mut().unwrap().get_mut().next_pcb = Some(next); in switch_process()
221 return (sp as *mut TrapFrame).as_mut().unwrap(); in task_trapframe()
/DragonOS/kernel/src/arch/x86_64/driver/
H A Dhpet.rs210 .as_mut() in timer_mut()
224 let regs = unsafe { inner.registers_ptr.as_mut() }; in hpet_regs_mut()
/DragonOS/kernel/src/smp/cpu/
H A Dmod.rs117 let p = (self as *const Self as *mut Self).as_mut().unwrap(); in set_possible_cpu()
147 let p = (self as *const Self as *mut Self).as_mut().unwrap(); in set_present_cpu()
/DragonOS/tools/debugging/logmonitor/src/backend/monitor/
H A Dlogset.rs53 .as_mut() in insert()
/DragonOS/kernel/src/sched/
H A Dmod.rs67 unsafe { CPU_IRQ_TIME.as_mut().unwrap()[cpu] } in cpu_irq_time()
370 .as_mut() in self_lock()
381 .as_mut() in self_lock()
983 .as_mut() in sched_init()
/DragonOS/kernel/src/virt/kvm/
H A Dhost_mem.rs150 let mapper = mapper.as_mut().unwrap(); in hva_to_pfn()
/DragonOS/kernel/src/libs/lib_ui/
H A Dscreen_manager.rs189 double_buffer_guard.as_mut().copy_from_slice(unsafe { in copy_from_nonoverlapping()
195 double_buffer_guard.as_mut().copy_from_slice(x.as_ref()); in copy_from_nonoverlapping()
H A Dtextui.rs336 return self.guard.as_mut().unwrap().as_mut(); in buf_mut()
1107 guard.as_mut().unwrap().textui_putchar_window( in textui_putstr()
/DragonOS/kernel/crates/rust-slabmalloc/src/
H A Dpages.rs435 let _ = self.head.as_mut().map(|n| { in pop()
529 self.p.as_mut() in resolve_mut()
/DragonOS/kernel/src/init/
H A Dcmdline.rs162 p.as_mut().unwrap() in force_mut()
217 p.as_mut().unwrap() in force_mut()
/DragonOS/kernel/src/driver/acpi/
H A Dmod.rs131 unsafe { RSDP_TMP_BOX.as_mut().unwrap()[0..size].copy_from_slice(tmp_data) }; in rsdp_paddr()
/DragonOS/kernel/src/process/
H A Dmod.rs221 .as_mut() in add_pcb()
460 ALL_PROCESS.lock_irqsave().as_mut().unwrap().remove(&pid); in release()
468 .as_mut() in switch_finish_hook()
475 .as_mut() in switch_finish_hook()
/DragonOS/kernel/src/filesystem/devpts/
H A Dmod.rs141 self.children.as_mut().unwrap() in children_unchecked_mut()

12