Searched refs:bytes (Results 1 – 10 of 10) sorted by relevance
/DragonOS/kernel/crates/intertrait/src/ |
H A D | hasher.rs | 17 fn write(&mut self, bytes: &[u8]) { in write() 18 let mut bytes = bytes; in write() localVariable 19 while bytes.len() > size_of::<u64>() { in write() 20 let (u64_bytes, remaining) = bytes.split_at(size_of::<u64>()); in write() 22 bytes = remaining in write() 24 self.0 ^= bytes in write()
|
/DragonOS/docs/kernel/memory_management/ |
H A D | mmio.md | 158 …bytes,那么可以令$exp = n$。index与exp的换算公式如下:$index = exp - 12$。e.g. 一个大小为$2^{12}$ bytes的内存块,其$exp = 12$,…
|
/DragonOS/kernel/src/mm/ |
H A D | ucontext.rs | 213 pub fn extend_stack(&mut self, mut bytes: usize) -> Result<(), SystemError> { in extend_stack() 219 bytes = page_align_up(bytes); in extend_stack() 220 stack.mapped_size += bytes; in extend_stack() 222 self.map_anonymous(len, bytes, prot_flags, map_flags, false, false)?; in extend_stack() 454 .find_free_at(self.mmap_min, vaddr, page_count.bytes(), map_flags)? in mmap() 458 .find_free(self.mmap_min, page_count.bytes()) in mmap() 580 let to_unmap = VirtRegion::new(start_page.virt_address(), page_count.bytes()); in munmap() 632 let region = VirtRegion::new(start_page.virt_address(), page_count.bytes()); in mprotect() 694 let region = VirtRegion::new(start_page.virt_address(), page_count.bytes()); in madvise() 1788 mut bytes: usize, in initial_extend() [all …]
|
/DragonOS/kernel/src/mm/allocator/ |
H A D | page_frame.rs | 186 pub fn bytes(&self) -> usize { in bytes() method 193 pub fn from_bytes(bytes: usize) -> Option<Self> { in from_bytes() 194 if bytes & MMArch::PAGE_OFFSET_MASK != 0 { in from_bytes() 197 return Some(Self(bytes / MMArch::PAGE_SIZE)); in from_bytes()
|
H A D | bump.rs | 109 PhysPageFrame::new(start_paddr + count.bytes()), in ensure_early_mapping()
|
/DragonOS/kernel/src/syscall/ |
H A D | misc.rs | 44 sysinfo.totalram = mem.total().bytes() as u64; in sysinfo() 45 sysinfo.freeram = mem.free().bytes() as u64 + slab_usage.free(); in sysinfo()
|
/DragonOS/kernel/src/process/ |
H A D | exec.rs | 285 let bytes = s.as_bytes_with_nul(); in push_str() localVariable 286 self.push_slice(ustack, bytes)?; in push_str()
|
/DragonOS/kernel/src/arch/riscv64/mm/ |
H A D | init.rs | 130 bump_allocator.usage().used().bytes() / 1024 in riscv_mm_init()
|
/DragonOS/kernel/src/filesystem/procfs/ |
H A D | mod.rs | 252 &mut format!("MemTotal:\t{} kB\n", usage.total().bytes() >> 10) in open_meminfo() 258 &mut format!("MemFree:\t{} kB\n", usage.free().bytes() >> 10) in open_meminfo()
|
/DragonOS/kernel/crates/rbpf/src/ |
H A D | cranelift.rs | 1016 let access_size = bcx.ins().iconst(I64, ty.bytes() as i64); in insert_bounds_check()
|