Returns the argument unchanged.
diff --git a/ch6/search-index.js b/ch6/search-index.js
index 7431abd4..358bf3a5 100644
--- a/ch6/search-index.js
+++ b/ch6/search-index.js
@@ -1,5 +1,5 @@
var searchIndex = JSON.parse('{\
-"os":{"doc":"The main module and entrypoint","t":[0,5,0,0,0,0,0,0,14,14,5,0,0,0,0,0,0,6,17,17,17,17,17,17,17,8,17,3,17,12,11,11,10,11,5,10,11,10,11,11,11,11,11,11,11,2,17,17,2,2,17,17,17,17,17,3,11,11,11,11,5,11,11,11,11,2,2,0,3,2,12,5,11,11,11,11,11,11,11,11,0,12,3,17,3,3,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,8,3,3,3,3,12,12,0,5,5,10,10,12,0,10,12,10,18,3,3,3,18,18,3,18,18,12,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,5,11,11,11,12,5,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,3,3,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,5,12,12,12,12,3,3,3,3,3,3,3,3,8,3,3,3,3,12,0,12,12,12,12,12,12,12,5,0,5,12,0,5,5,0,0,12,12,5,12,10,5,5,5,5,12,12,12,12,17,17,3,3,3,3,8,17,6,17,3,3,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,12,10,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,3,8,6,3,3,12,10,11,11,11,11,11,11,11,12,10,11,11,11,12,11,5,5,5,11,11,11,11,5,11,11,11,10,11,11,12,12,11,11,11,11,11,11,11,11,11,7,7,5,5,5,13,13,3,3,3,4,3,18,18,18,18,12,11,11,12,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,5,5,5,11,11,11,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,5,11,11,12,11,12,11,11,11,11,11,12,11,11,11,5,11,11,5,5,11,5,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,18,18,18,3,3,3,18,18,3,3,18,18,18,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,5,5,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,17,17,17,17,17,17,17,17,17,5,5,5,5,5,3,12,0,3,11,11,11,11,12,11,11,11,11,11,17,17,17,17,17,17,17,17,17,17,17,0,0,5,5,5,5,5,5,5,5,5,5,5,5,12,17,3,3,3,3,3,3,3,12,5,5,11,11,0,12,12,5,5,5,11,5,5,11,12,11,0,0,12,5,0,12,12,12,5,12,5,12,5,0,5,0,11,11,11,3,11,11,11,11,11,12,12,12,11,11,11,11,3,3,12,11,5,11,11,11,11,11,11,5,11,11,11,11,11,12,11,11,11,11,11,11,12,3,3,3,3,12,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,5,11,11,12,5,11,12,11,11,11,11,11,11,11,11,11,11,11,11,3,3,12,11,11,11,11,11,12,5,5,5,11,11,11,11,12,11,11,11,5,5,11,5,11,11,11,11,11,11,5,13,13,3,3,4,13,11,12,11,11,11,11,11,11,12,11,11,11,11,12,12,11,11,11,11,11,11,11,11,12,11,11,11,11,11,12,12,11,12,12,12,12,11,12,11,11,11,11,11,11,11,11,11,17,17,5,5,5,3,0,5,5,12,12,12,5,5,12,5,5,12,5,12,3,11,11,11,11,11,11,12,12,12,11,12,12,11,11,11,12],"n":["board","clear_bss","config","console","drivers","fs","lang_items","mm","print","println","rust_main","sbi","sync","syscall","task","timer","trap","BlockDeviceImpl","CLOCK_FREQ","EXIT_FAILURE","EXIT_FAILURE_FLAG","EXIT_RESET","EXIT_SUCCESS","MEMORY_END","MMIO","QEMUExit","QEMU_EXIT_HANDLE","RISCV64","VIRT_TEST","addr","borrow","borrow_mut","exit","exit","exit_code_encode","exit_failure","exit_failure","exit_success","exit_success","from","into","new","try_from","try_into","type_id","CLOCK_FREQ","KERNEL_HEAP_SIZE","KERNEL_STACK_SIZE","MEMORY_END","MMIO","PAGE_SIZE","PAGE_SIZE_BITS","TRAMPOLINE","TRAP_CONTEXT","USER_STACK_SIZE","Stdout","borrow","borrow_mut","from","into","print","try_from","try_into","type_id","write_str","BLOCK_DEVICE","BLOCK_DEVICE","block","BLOCK_DEVICE","VirtIOBlock","__private_field","block_device_test","borrow","borrow_mut","deref","from","into","try_from","try_into","type_id","virtio_blk","0","QUEUE_FRAMES","VIRTIO0","VirtIOBlock","VirtioHal","__private_field","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","deref","dma_alloc","dma_dealloc","from","from","from","into","into","into","new","phys_to_virt","read_block","try_from","try_from","try_from","try_into","try_into","try_into","type_id","type_id","type_id","virt_to_phys","write_block","File","OSInode","OpenFlags","Stdin","Stdout","bits","inner","inode","list_apps","open_file","read","readable","readable","stdio","writable","writable","write","CREATE","OSInode","OSInodeInner","OpenFlags","RDONLY","RDWR","ROOT_INODE","TRUNC","WRONLY","__private_field","all","bitand","bitand_assign","bitor","bitor_assign","bits","bits","bitxor","bitxor_assign","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone_into","cmp","complement","contains","deref","difference","empty","eq","extend","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from_bits","from_bits_truncate","from_bits_unchecked","from_iter","hash","inner","inode","insert","intersection","intersects","into","into","into","into","is_all","is_empty","list_apps","ne","new","not","offset","open_file","partial_cmp","read","read_all","read_write","readable","readable","remove","set","sub","sub_assign","symmetric_difference","to_owned","toggle","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","union","writable","writable","write","Stdin","Stdout","borrow","borrow","borrow_mut","borrow_mut","from","from","into","into","read","read","readable","readable","try_from","try_from","try_into","try_into","type_id","type_id","writable","writable","write","write","panic","0","0","0","0","FrameTracker","KERNEL_SPACE","MapPermission","MemorySet","PageTable","PageTableEntry","PhysAddr","PhysPageNum","StepByOne","UserBuffer","UserBufferIterator","VirtAddr","VirtPageNum","__private_field","address","areas","bits","bits","buffers","buffers","current_buffer","current_idx","frame_alloc","frame_allocator","frame_dealloc","frames","heap_allocator","init","kernel_token","memory_set","page_table","page_table","ppn","remap_test","root_ppn","step","translated_byte_buffer","translated_ref","translated_refmut","translated_str","0","0","0","0","PA_WIDTH_SV39","PPN_WIDTH_SV39","PhysAddr","PhysPageNum","SimpleRange","SimpleRangeIterator","StepByOne","VA_WIDTH_SV39","VPNRange","VPN_WIDTH_SV39","VirtAddr","VirtPageNum","aligned","aligned","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","ceil","ceil","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","cmp","cmp","cmp","cmp","current","end","eq","eq","eq","eq","floor","floor","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","from","from","from","from","from","get_bytes_array","get_end","get_mut","get_mut","get_pte_array","get_ref","get_start","indexes","into","into","into","into","into","into","into_iter","into_iter","l","ne","ne","ne","ne","new","new","next","page_offset","page_offset","partial_cmp","partial_cmp","partial_cmp","partial_cmp","r","step","step","step","to_owned","to_owned","to_owned","to_owned","to_owned","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","FRAME_ALLOCATOR","FrameAllocator","FrameAllocatorImpl","FrameTracker","StackFrameAllocator","__private_field","alloc","alloc","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","current","dealloc","dealloc","deref","drop","end","fmt","frame_alloc","frame_allocator_test","frame_dealloc","from","from","from","init","init_frame_allocator","into","into","into","new","new","new","ppn","recycled","try_from","try_from","try_from","try_into","try_into","try_into","type_id","type_id","type_id","HEAP_ALLOCATOR","HEAP_SPACE","handle_alloc_error","heap_test","init_heap","Framed","Identical","KERNEL_SPACE","MapArea","MapPermission","MapType","MemorySet","R","U","W","X","__private_field","activate","all","areas","bitand","bitand_assign","bitor","bitor_assign","bits","bits","bitxor","bitxor_assign","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone","clone_into","clone_into","cmp","complement","contains","copy_data","data_frames","deref","difference","ebss","edata","ekernel","empty","eq","eq","erodata","etext","extend","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from_another","from_bits","from_bits_truncate","from_bits_unchecked","from_elf","from_existed_user","from_iter","hash","insert","insert_framed_area","intersection","intersects","into","into","into","into","into","is_all","is_empty","kernel_token","map","map_one","map_perm","map_trampoline","map_type","ne","new","new_bare","new_kernel","not","page_table","partial_cmp","push","recycle_data_pages","remap_test","remove","remove_area_with_start_vpn","sbss_with_stack","sdata","set","srodata","stext","strampoline","sub","sub_assign","symmetric_difference","to_owned","to_owned","toggle","token","translate","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","union","unmap","unmap_one","vpn_range","A","D","G","PTEFlags","PageTable","PageTableEntry","R","U","UserBuffer","UserBufferIterator","V","W","X","all","bitand","bitand_assign","bitor","bitor_assign","bits","bits","bits","bitxor","bitxor_assign","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","buffers","buffers","clone","clone","clone_into","clone_into","cmp","complement","contains","current_buffer","current_idx","difference","empty","empty","eq","executable","extend","find_pte","find_pte_create","flags","fmt","fmt","fmt","fmt","fmt","frames","from","from","from","from","from","from_bits","from_bits_truncate","from_bits_unchecked","from_iter","from_token","hash","insert","intersection","intersects","into","into","into","into","into","into_iter","into_iter","is_all","is_empty","is_valid","len","map","ne","new","new","new","next","not","partial_cmp","ppn","readable","remove","root_ppn","set","sub","sub_assign","symmetric_difference","to_owned","to_owned","toggle","token","translate","translate_va","translated_byte_buffer","translated_ref","translated_refmut","translated_str","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","union","unmap","writable","SBI_CLEAR_IPI","SBI_CONSOLE_GETCHAR","SBI_CONSOLE_PUTCHAR","SBI_REMOTE_FENCE_I","SBI_REMOTE_SFENCE_VMA","SBI_REMOTE_SFENCE_VMA_ASID","SBI_SEND_IPI","SBI_SET_TIMER","SBI_SHUTDOWN","console_getchar","console_putchar","sbi_call","set_timer","shutdown","UPSafeCell","inner","up","UPSafeCell","borrow","borrow_mut","exclusive_access","from","inner","into","new","try_from","try_into","type_id","SYSCALL_CLOSE","SYSCALL_EXEC","SYSCALL_EXIT","SYSCALL_FORK","SYSCALL_GETPID","SYSCALL_GET_TIME","SYSCALL_OPEN","SYSCALL_READ","SYSCALL_WAITPID","SYSCALL_WRITE","SYSCALL_YIELD","fs","process","syscall","sys_close","sys_open","sys_read","sys_write","sys_exec","sys_exit","sys_fork","sys_get_time","sys_getpid","sys_waitpid","sys_yield","0","IDLE_PID","INITPROC","KernelStack","PidAllocator","PidHandle","Processor","TaskContext","TaskManager","__private_field","add_initproc","add_task","borrow","borrow_mut","context","current","current","current_task","current_trap_cx","current_user_token","deref","exit_current_and_run_next","fetch_task","from","idle_task_cx","into","manager","pid","pid","pid_alloc","processor","ra","ready_queue","recycled","run_tasks","s","schedule","sp","suspend_current_and_run_next","switch","take_current_task","task","try_from","try_into","type_id","TaskContext","borrow","borrow_mut","from","goto_trap_return","into","ra","s","sp","try_from","try_into","type_id","zero_init","TASK_MANAGER","TaskManager","__private_field","add","add_task","borrow","borrow","borrow_mut","borrow_mut","deref","fetch","fetch_task","from","from","into","into","new","ready_queue","try_from","try_from","try_into","try_into","type_id","type_id","0","KernelStack","PID_ALLOCATOR","PidAllocator","PidHandle","__private_field","alloc","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","current","dealloc","deref","drop","drop","from","from","from","from","get_top","into","into","into","into","kernel_stack_position","new","new","pid","pid_alloc","push_on_top","recycled","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","PROCESSOR","Processor","__private_field","borrow","borrow","borrow_mut","borrow_mut","current","current","current_task","current_trap_cx","current_user_token","deref","from","from","get_idle_task_cx_ptr","idle_task_cx","into","into","new","run_tasks","schedule","take_current","take_current_task","try_from","try_from","try_into","try_into","type_id","type_id","__switch","Ready","Running","TaskControlBlock","TaskControlBlockInner","TaskStatus","Zombie","alloc_fd","base_size","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","children","clone","clone_into","eq","exec","exit_code","fd_table","fork","from","from","from","get_status","get_trap_cx","get_user_token","getpid","inner","inner_exclusive_access","into","into","into","is_zombie","kernel_stack","memory_set","new","parent","pid","task_cx","task_status","to_owned","trap_cx_ppn","try_from","try_from","try_from","try_into","try_into","try_into","type_id","type_id","type_id","MSEC_PER_SEC","TICKS_PER_SEC","get_time","get_time_ms","set_next_trigger","TrapContext","context","enable_timer_interrupt","init","kernel_satp","kernel_sp","sepc","set_kernel_trap_entry","set_user_trap_entry","sstatus","trap_from_kernel","trap_handler","trap_handler","trap_return","x","TrapContext","app_init_context","borrow","borrow_mut","fmt","from","into","kernel_satp","kernel_sp","sepc","set_sp","sstatus","trap_handler","try_from","try_into","type_id","x"],"q":["os","","","","","","","","","","","","","","","","","os::board","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::config","","","","","","","","","","os::console","","","","","","","","","","os::drivers","","","os::drivers::block","","","","","","","","","","","","","os::drivers::block::virtio_blk","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::fs","","","","","","","","","","","","","","","","","os::fs::inode","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::fs::stdio","","","","","","","","","","","","","","","","","","","","","","","","os::lang_items","os::mm","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::address","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::frame_allocator","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::heap_allocator","","","","","os::mm::memory_set","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::page_table","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::sbi","","","","","","","","","","","","","","os::sync","","","os::sync::up","","","","","","","","","","","os::syscall","","","","","","","","","","","","","","os::syscall::fs","","","","os::syscall::process","","","","","","","os::task","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::task::context","","","","","","","","","","","","","os::task::manager","","","","","","","","","","","","","","","","","","","","","","","","os::task::pid","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::task::processor","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::task::switch","os::task::task","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::timer","","","","","os::trap","","","","","","","","","","","","","","","os::trap::context","","","","","","","","","","","","","","","",""],"d":["","clear BSS segment","Constants used in rCore","SBI console driver, for text output","","File system in os","The panic handler","Memory management implementation","print string macro","println string macro","the rust entry-point of os","SBI call wrappers","Synchronization and interior mutability primitives","Implementation of syscalls","Task management implementation","RISC-V timer-related functionality","Trap handling functionality","","","","","","","","","","","RISCV64 configuration","","Address of the sifive_test mapped device.","","","Exit with specified return code.","Exit qemu with specified exit code.","Encode the exit code using EXIT_FAILURE_FLAG.","Exit QEMU using
EXIT_FAILURE
, aka
1
.","","Exit QEMU using
EXIT_SUCCESS
, aka
0
, if possible.","","Returns the argument unchanged.","Calls
U::from(self)
.","Create an instance.","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","Returns the argument unchanged.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","","","","","File trait","A wrapper around a filesystem inode to implement File …","Open file flags","Standard input","Standard output","","","
Arc<Inode>
->
OSInodeInner
: In order to open files …","List all files in the filesystems","Open file with flags","Read file to
UserBuffer
","If readable","","Stdin & Stdout","If writable","","Write
UserBuffer
to file","Allow create","A wrapper around a filesystem inode to implement File …","The OS inode inner in ‘UPSafeCell’","Open file flags","Read only","Read & Write","","Clear file and return an empty one","Write only","","Returns the set containing all flags.","Returns the intersection between the two sets of flags.","Disables all flags disabled in the set.","Returns the union of the two sets of flags.","Adds the set of flags.","Returns the raw value of the flags currently stored.","","Returns the left flags, but with all the right flags …","Toggles the set of flags.","","","","","","","","","","","","Returns the complement of this set of flags.","Returns
true
if all of the flags in
other
are contained …","","Returns the difference between the flags in
self
and
other
.","Returns an empty set of flags.","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Convert from underlying bit representation, unless that …","Convert from underlying bit representation, dropping any …","Convert from underlying bit representation, preserving all …","","","","","Inserts the specified flags in-place.","Returns the intersection between the flags in
self
and …","Returns
true
if there are flags common to both
self
and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Returns
true
if all flags are currently set.","Returns
true
if no flags are currently stored.","List all files in the filesystems","","Construct an OS inode from a inode","Returns the complement of this set of flags.","","Open file with flags","","","Read all data inside a inode into vector","Do not check validity for simplicity Return (readable, …","","","Removes the specified flags in-place.","Inserts or removes the specified flags depending on the …","Returns the set difference of the two sets of flags.","Disables all flags enabled in the set.","Returns the symmetric difference between the flags in
self
…","","Toggles the specified flags in-place.","","","","","","","","","","","","","Returns the union of between the flags in
self
and
other
.","","","","Standard input","Standard output","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","","","","","manage a frame which has the same lifecycle as the tracker","a memory set instance through lazy_static! managing kernel …","map permission corresponding to that in pte:
R W X U
","memory set structure, controls virtual-memory space","Record root ppn and has the same lifetime as 1 and 2 level …","page table entry structure","Definitions","phiscal page number","Add value by one","Array of u8 slice that user communicate with os","Iterator of
UserBuffer
","virtual address","virtual page number","","Implementation of physical and virtual address and page …","","","PTE","U8 vec","","","","allocate a frame","Implementation of
FrameAllocator
which controls all the …","deallocate a frame","","The global allocator","initiate heap allocator, frame allocator and kernel space","Get kernelspace root ppn","Implementation of
MapArea
and
MemorySet
.","Implementation of
PageTableEntry
and
PageTable
.","","","Check PageTable running correctly","","Add value by one","Translate a pointer to a mutable u8 Vec through page table","Translate a generic through page table and return a …","Translate a generic through page table and return a …","Translate a pointer to a mutable u8 Vec end with
\\\\0
…","","","","","","","Definitions","phiscal page number","a simple range structure for type T","iterator for the simple range structure","Add value by one","","a simple range structure for virtual page number","","virtual address","virtual page number","Check page aligned","Check page aligned","","","","","","","","","","","","","
PhysAddr
->
PhysPageNum
","
VirtAddr
->
VirtPageNum
","","","","","","","","","","","","","","","","","","","","","
PhysAddr
->
PhysPageNum
","
VirtAddr
->
VirtPageNum
","","","","","Returns the argument unchanged.","","Returns the argument unchanged.","","","","Returns the argument unchanged.","","","Returns the argument unchanged.","","","Returns the argument unchanged.","Returns the argument unchanged.","Get u8 array on
PhysPageNum
","","Get mutable reference to
PhysAddr
value","Get Get mutable reference to
PhysAddr
value on
PhysPageNum
","Get
PageTableEntry
on
PhysPageNum
","Get reference to
PhysAddr
value","","Return VPN 3 level index","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","Get page offset","Get page offset","","","","","","Add value by one","","","","","","","","","","","","","","","","","","","","","","","","","","frame allocator instance through lazy_static!","","","manage a frame which has the same lifecycle as the tracker","an implementation for frame allocator","","","","","","","","","","","","","","","","","allocate a frame","a simple test for frame allocator","deallocate a frame","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","initiate the frame allocator using
ekernel
and
MEMORY_END
","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","Create an empty
FrameTracker
","","","","","","","","","","","","","heap allocator instance","heap space ([u8; KERNEL_HEAP_SIZE])","panic when heap allocation error occurs","","initiate heap allocator","","","a memory set instance through lazy_static! managing kernel …","map area structure, controls a contiguous piece of virtual …","map permission corresponding to that in pte:
R W X U
","map type for memory set: identical or framed","memory set structure, controls virtual-memory space","Readable","Accessible in U mode","Writable","Excutable","","Refresh TLB with
sfence.vma
","Returns the set containing all flags.","","Returns the intersection between the two sets of flags.","Disables all flags disabled in the set.","Returns the union of the two sets of flags.","Adds the set of flags.","Returns the raw value of the flags currently stored.","","Returns the left flags, but with all the right flags …","Toggles the set of flags.","","","","","","","","","","","","","","","","Returns the complement of this set of flags.","Returns
true
if all of the flags in
other
are contained …","data: start-aligned but maybe with shorter length assume …","","","Returns the difference between the flags in
self
and
other
.","","","","Returns an empty set of flags.","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","Convert from underlying bit representation, unless that …","Convert from underlying bit representation, dropping any …","Convert from underlying bit representation, preserving all …","Include sections in elf and trampoline and TrapContext and …","Clone a same
MemorySet
","","","Inserts the specified flags in-place.","Assume that no conflicts.","Returns the intersection between the flags in
self
and …","Returns
true
if there are flags common to both
self
and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Returns
true
if all flags are currently set.","Returns
true
if no flags are currently stored.","Get kernelspace root ppn","","","","Mention that trampoline is not collected by areas.","","","","Create an empty
MemorySet
","Without kernel stacks.","Returns the complement of this set of flags.","","","","Remove all
MapArea
","Check PageTable running correctly","Removes the specified flags in-place.","Remove
MapArea
that starts with
start_vpn
","","","Inserts or removes the specified flags depending on the …","","","","Returns the set difference of the two sets of flags.","Disables all flags enabled in the set.","Returns the symmetric difference between the flags in
self
…","","","Toggles the specified flags in-place.","Get pagetable
root_ppn
","Translate throuth pagetable","","","","","","","","","","","","","","","","Returns the union of between the flags in
self
and
other
.","","","","","","","","Record root ppn and has the same lifetime as 1 and 2 level …","page table entry structure","","","Array of u8 slice that user communicate with os","Iterator of
UserBuffer
","","","","Returns the set containing all flags.","Returns the intersection between the two sets of flags.","Disables all flags disabled in the set.","Returns the union of the two sets of flags.","Adds the set of flags.","Returns the raw value of the flags currently stored.","","PTE","Returns the left flags, but with all the right flags …","Toggles the set of flags.","","","","","","","","","","","U8 vec","","","","","","","Returns the complement of this set of flags.","Returns
true
if all of the flags in
other
are contained …","","","Returns the difference between the flags in
self
and
other
.","Returns an empty set of flags.","Return an empty PTE","","Check PTE executable","","Find phsical address by virtual address","Find phsical address by virtual address, create a frame if …","Return 10bit flag","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Convert from underlying bit representation, unless that …","Convert from underlying bit representation, dropping any …","Convert from underlying bit representation, preserving all …","","Temporarily used to get arguments from user space.","","Inserts the specified flags in-place.","Returns the intersection between the flags in
self
and …","Returns
true
if there are flags common to both
self
and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","Returns
true
if all flags are currently set.","Returns
true
if no flags are currently stored.","Check PTE valid","Length of
UserBuffer
","Create a mapping form
vpn
to
ppn
","","Create an empty
PageTable
","Create a
UserBuffer
by parameter","Create a PTE from ppn","","Returns the complement of this set of flags.","","Return 44bit ppn","Check PTE readable","Removes the specified flags in-place.","","Inserts or removes the specified flags depending on the …","Returns the set difference of the two sets of flags.","Disables all flags enabled in the set.","Returns the symmetric difference between the flags in
self
…","","","Toggles the specified flags in-place.","Get root ppn","Translate
VirtPageNum
to
PageTableEntry
","Translate
VirtAddr
to
PhysAddr
","Translate a pointer to a mutable u8 Vec through page table","Translate a generic through page table and return a …","Translate a generic through page table and return a …","Translate a pointer to a mutable u8 Vec end with
\\\\0
…","","","","","","","","","","","","","","","","Returns the union of between the flags in
self
and
other
.","Delete a mapping form
vpn
","Check PTE writable","","","","","","","","","","use sbi call to getchar from console (qemu uart handler)","use sbi call to putchar in console (qemu uart handler)","general sbi call","use sbi call to set timer","use sbi call to shutdown the kernel","Wrap a static data structure inside it so that we are able …","inner data","Uniprocessor interior mutability primitives","Wrap a static data structure inside it so that we are able …","","","Exclusive access inner data in UPSafeCell. Panic if the …","Returns the argument unchanged.","inner data","Calls
U::from(self)
.","User is responsible to guarantee that inner struct is only …","","","","","","","","","","","","","","","File and filesystem-related syscalls","","handle syscall exception with
syscall_id
and other …","","","","","","","","","","If there is not a child process whose pid is same as …","","","pid of usertests app in make run TEST=1","Globle process that init user shell","Kernelstack for app","Pid Allocator struct","Bind pid lifetime to
PidHandle
","Processor management structure","task context structure containing some registers","A array of
TaskControlBlock
that is thread-safe","","Add init process to the manager","Interface offered to add task","","","Implementation of
TaskContext
","","The task currently executing on the current processor","Get running task","Get the mutable reference to trap context of current task","Get token of the address space of current task","","Exit the current ‘Running’ task and run the next task …","Interface offered to pop the first task","Returns the argument unchanged.","The basic control flow of each core, helping to select and …","Calls
U::from(self)
.","Implementation of
TaskManager
","Implementation of
PidAllocator
","","Allocate a pid from PID_ALLOCATOR","Implementation of
Processor
and Intersection of control …","return address ( e.g. __restore ) of __switch ASM function","","","The main part of process execution and scheduling Loop …","s0-11 register, callee saved","Return to idle control flow for new scheduling","kernel stack pointer of app","Suspend the current ‘Running’ task and run the next …","Wrap
switch.S
as a function","Take the current task,leaving a None in its place","Implementation of
TaskControlBlock
","","","","task context structure containing some registers","","","Returns the argument unchanged.","set Task Context{__restore ASM funciton: trap_return, sp: …","Calls
U::from(self)
.","return address ( e.g. __restore ) of __switch ASM function","s0-11 register, callee saved","kernel stack pointer of app","","","","init task context","","A array of
TaskControlBlock
that is thread-safe","","Add a task to
TaskManager
","Interface offered to add task","","","","","","Remove the first task and return it,or
None
if
TaskManager
…","Interface offered to pop the first task","Returns the argument unchanged.","Returns the argument unchanged.","Calls
U::from(self)
.","Calls
U::from(self)
.","Creat an empty TaskManager","","","","","","","","","Kernelstack for app","","Pid Allocator struct","Bind pid lifetime to
PidHandle
","","Allocate a pid","","","","","","","","","","Recycle a pid","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Get the value on the top of kernelstack","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Return (bottom, top) of a kernel stack in kernel space.","Create an empty
PidAllocator
","Create a kernelstack from pid","","Allocate a pid from PID_ALLOCATOR","Push a value on top of kernelstack","","","","","","","","","","","","","","","Processor management structure","","","","","","Get current task in cloning semanteme","The task currently executing on the current processor","Get running task","Get the mutable reference to trap context of current task","Get token of the address space of current task","","Returns the argument unchanged.","Returns the argument unchanged.","Get mutable reference to
idle_task_cx
","The basic control flow of each core, helping to select and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Create an empty Processor","The main part of process execution and scheduling Loop …","Return to idle control flow for new scheduling","Get current task in moving semanteme","Take the current task,leaving a None in its place","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","","","","","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","","","","","","","get current time","get current time in microseconds","set the next timer interrupt","trap context structure containing sstatus, sepc and …","Implementation of
TrapContext
","enable timer interrupt in sie CSR","initialize CSR
stvec
as the entry of
__alltraps
","Addr of Page Table","kernel stack","CSR sepc","","","CSR sstatus ","Unimplement: traps/interrupts/exceptions from kernel mode …","handle an interrupt, exception, or system call from user …","Addr of trap_handler function","set the new addr of __restore asm function in TRAMPOLINE …","general regs[0..31]","trap context structure containing sstatus, sepc and …","init app context","","","","Returns the argument unchanged.","Calls
U::from(self)
.","Addr of Page Table","kernel stack","CSR sepc","set stack pointer to x_2 reg (sp)","CSR sstatus ","Addr of trap_handler function","","","","general regs[0..31]"],"i":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,3,3,70,3,0,70,3,70,3,3,3,3,3,3,3,0,0,0,0,0,0,0,0,0,0,0,8,8,8,8,0,8,8,8,8,0,0,0,0,0,11,0,11,11,11,11,11,11,11,11,0,17,0,0,0,0,13,17,71,13,17,71,13,13,71,71,17,71,13,17,71,13,17,71,17,17,71,13,17,71,13,17,71,13,71,17,0,0,0,0,0,18,19,0,0,0,72,72,19,0,72,19,72,18,0,0,0,18,18,0,18,18,24,18,18,18,18,18,18,18,18,18,19,73,24,18,19,73,24,18,18,18,18,18,18,24,18,18,18,18,18,18,18,18,18,19,73,24,18,18,18,18,18,18,19,73,18,18,18,19,73,24,18,18,18,0,18,19,18,73,0,18,19,19,18,19,19,18,18,18,18,18,18,18,19,73,24,18,19,73,24,18,19,73,24,18,18,19,19,19,0,0,30,31,30,31,30,31,30,31,30,31,30,31,30,31,30,31,30,31,30,31,30,31,0,36,37,34,38,0,0,0,0,0,0,0,0,0,0,0,0,0,50,0,45,46,51,21,53,53,53,0,0,0,49,0,0,0,0,0,45,33,0,49,74,0,0,0,0,36,37,34,38,0,0,0,0,0,0,0,0,0,0,0,0,36,37,41,36,37,34,38,40,41,36,37,34,38,40,36,37,36,37,34,38,40,36,37,34,38,40,36,37,34,38,41,41,36,37,34,38,36,37,36,37,34,38,41,36,36,36,37,37,37,34,34,34,38,38,38,40,34,40,36,34,34,36,40,38,41,36,37,34,38,40,41,40,40,36,37,34,38,41,40,41,36,37,36,37,34,38,40,74,34,38,36,37,34,38,40,41,36,37,34,38,40,41,36,37,34,38,40,41,36,37,34,38,40,0,0,0,0,0,43,75,42,33,42,43,33,42,43,42,75,42,43,33,42,33,0,0,0,33,42,43,42,0,33,42,43,75,33,42,33,42,33,42,43,33,42,43,33,42,43,0,0,0,0,0,47,47,0,0,0,0,0,46,46,46,46,50,45,46,45,46,46,46,46,46,46,46,46,45,48,50,47,46,45,48,50,47,46,47,46,47,46,46,46,46,48,48,50,46,0,0,0,46,47,46,0,0,46,47,46,46,46,46,46,45,48,50,47,46,48,46,46,46,45,45,46,46,46,45,46,46,45,48,50,47,46,46,46,0,48,48,48,45,48,46,48,45,45,46,45,46,45,45,0,46,45,0,0,46,0,0,0,46,46,46,47,46,46,45,45,45,48,50,47,46,45,48,50,47,46,45,48,50,47,46,46,48,48,48,52,52,52,0,0,0,52,52,0,0,52,52,52,52,52,52,52,52,52,52,51,52,52,49,21,53,52,51,49,21,53,52,51,21,53,52,51,52,51,52,52,52,53,53,52,52,51,52,51,52,49,49,51,52,52,52,52,52,49,49,21,53,52,51,52,52,52,52,49,52,52,52,52,49,21,53,52,51,21,53,52,52,51,21,49,52,49,21,51,53,52,52,51,51,52,49,52,52,52,52,52,51,52,49,49,49,0,0,0,0,49,21,53,52,51,49,21,53,52,51,49,21,53,52,51,52,49,51,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,14,0,0,14,14,14,14,14,14,14,14,14,14,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,59,0,0,0,0,0,0,0,0,58,0,0,58,58,0,63,66,0,0,0,58,0,0,58,66,58,0,0,65,0,0,60,61,63,0,60,0,60,0,0,0,0,58,58,58,0,60,60,60,60,60,60,60,60,60,60,60,60,0,0,62,61,0,61,62,61,62,62,61,0,61,62,61,62,61,61,61,62,61,62,61,62,59,0,0,0,0,64,63,63,59,65,64,63,59,65,64,63,63,64,59,65,63,59,65,64,65,63,59,65,64,0,63,65,65,0,65,63,63,59,65,64,63,59,65,64,63,59,65,64,0,0,67,66,67,66,67,66,66,0,0,0,67,66,67,66,66,66,67,66,0,0,66,0,66,67,66,67,66,67,0,69,69,0,0,0,69,68,68,56,68,69,56,68,69,68,69,69,69,56,68,68,56,56,68,69,68,68,68,56,56,56,56,68,69,68,56,68,56,68,56,68,68,69,68,56,68,69,56,68,69,56,68,69,0,0,0,0,0,0,0,0,0,57,57,57,0,0,57,0,0,57,0,57,0,57,57,57,57,57,57,57,57,57,57,57,57,57,57,57,57],"f":[0,[[]],0,0,0,0,0,0,0,0,[[],1],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[]],[[]],[2,1],[[3,2],1],[2,2],[[],1],[3,1],[[],1],[3,1],[[]],[[]],[4,3],[[],5],[[],5],[[],6],0,0,0,0,0,0,0,0,0,0,0,[[]],[[]],[[]],[[]],[7],[[],5],[[],5],[[],6],[[8,9],10],0,0,0,0,0,0,[[]],[[]],[[]],[11,12],[[]],[[]],[[],5],[[],5],[[],6],0,0,0,0,0,0,0,[[]],[[]],[[]],[[]],[[]],[[]],[13,14],[15,15],[[15,15],16],[[]],[[]],[[]],[[]],[[]],[[]],[[],17],[15,15],[[17,15]],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],[15,15],[[17,15]],0,0,0,0,0,0,0,0,[[]],[[9,18],[[20,[[12,[19]]]]]],[21,15],[[],22],0,0,[[],22],0,[21,15],0,0,0,0,0,0,0,0,0,0,[[],18],[[18,18],18],[[18,18]],[[18,18],18],[[18,18]],[18,2],0,[[18,18],18],[[18,18]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[18,18],[[]],[[18,18],23],[18,18],[[18,18],22],[24,12],[[18,18],18],[[],18],[[18,18],22],[[18,25]],[[18,26],10],[[18,26],10],[[18,26],10],[[18,26],10],[[18,26],10],[[]],[[]],[[]],[[]],[2,[[20,[18]]]],[2,18],[2,18],[25,18],[18],0,0,[[18,18]],[[18,18],18],[[18,18],22],[[]],[[]],[[]],[[]],[18,22],[18,22],[[]],[[18,18],22],[[22,22,[12,[27]]],19],[18,18],0,[[9,18],[[20,[[12,[19]]]]]],[[18,18],[[20,[23]]]],[[19,21],15],[19,[[29,[28]]]],[18],[19,22],0,[[18,18]],[[18,18,22]],[[18,18],18],[[18,18]],[[18,18],18],[[]],[[18,18]],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],[[],6],[[18,18],18],[19,22],0,[[19,21],15],0,0,[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[30,21],15],[[31,21],15],[30,22],[31,22],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[30,22],[31,22],[[30,21],15],[[31,21],15],[32,1],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[],[[20,[33]]]],0,[34],0,0,[[]],[[],15],0,0,0,0,[[]],0,[[]],[[15,28,15],29],[15],[15],[[15,28],35],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[36,22],[37,22],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[36,34],[37,38],[36,36],[37,37],[34,34],[38,38],[[[40,[39]]],[[40,[39]]]],[[]],[[]],[[]],[[]],[[]],[[36,36],23],[[37,37],23],[[34,34],23],[[38,38],23],0,0,[[36,36],22],[[37,37],22],[[34,34],22],[[38,38],22],[36,34],[37,38],[[36,26],10],[[37,26],10],[[34,26],10],[[38,26],10],[[]],[34,36],[[]],[15,36],[38,37],[15,37],[[]],[36,34],[15,34],[[]],[37,38],[15,38],[[]],[[]],[34],[40],[36],[34],[34],[36],[40],[38],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[40],0,[[36,36],22],[[37,37],22],[[34,34],22],[[38,38],22],[[],41],[[],40],[41,20],[36,15],[37,15],[[36,36],[[20,[23]]]],[[37,37],[[20,[23]]]],[[34,34],[[20,[23]]]],[[38,38],[[20,[23]]]],0,[[]],[34],[38],[[]],[[]],[[]],[[]],[[]],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],[[],6],[[],6],[[],6],0,0,0,0,0,0,[[],[[20,[34]]]],[42,[[20,[34]]]],[[]],[[]],[[]],[[]],[[]],[[]],0,[34],[[42,34]],[43,14],[33],0,[[33,26],10],[[],[[20,[33]]]],[[]],[34],[[]],[[]],[[]],[[42,34,34]],[[]],[[]],[[]],[[]],[[]],[34,33],[[],42],0,0,[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],0,0,[44,1],[[]],[[]],0,0,0,0,0,0,0,0,0,0,0,0,[45],[[],46],0,[[46,46],46],[[46,46]],[[46,46],46],[[46,46]],[46,28],0,[[46,46],46],[[46,46]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[47,47],[46,46],[[]],[[]],[[46,46],23],[46,46],[[46,46],22],[[48,49]],0,[50,12],[[46,46],46],0,0,0,[[],46],[[47,47],22],[[46,46],22],0,0,[[46,25]],[[47,26],10],[[46,26],10],[[46,26],10],[[46,26],10],[[46,26],10],[[46,26],10],[[]],[[]],[[]],[[]],[[]],[48,48],[28,[[20,[46]]]],[28,46],[28,46],[[]],[45,45],[25,46],[46],[[46,46]],[[45,37,37,46]],[[46,46],46],[[46,46],22],[[]],[[]],[[]],[[]],[[]],[46,22],[46,22],[[],15],[[48,49]],[[48,49,38]],0,[45],0,[[46,46],22],[[37,37,47,46],48],[[],45],[[],45],[46,46],0,[[46,46],[[20,[23]]]],[[45,48,20]],[45],[[]],[[46,46]],[[45,38]],0,0,[[46,46,22]],0,0,0,[[46,46],46],[[46,46]],[[46,46],46],[[]],[[]],[[46,46]],[45,15],[[45,38],[[20,[51]]]],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],[[],6],[[],6],[[46,46],46],[[48,49]],[[48,49,38]],0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[],52],[[52,52],52],[[52,52]],[[52,52],52],[[52,52]],[52,28],0,0,[[52,52],52],[[52,52]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,0,[52,52],[51,51],[[]],[[]],[[52,52],23],[52,52],[[52,52],22],0,0,[[52,52],52],[[],52],[[],51],[[52,52],22],[51,22],[[52,25]],[[49,38],[[20,[51]]]],[[49,38],[[20,[51]]]],[51,52],[[52,26],10],[[52,26],10],[[52,26],10],[[52,26],10],[[52,26],10],0,[[]],[[]],[[]],[[]],[[]],[28,[[20,[52]]]],[28,52],[28,52],[25,52],[15,49],[52],[[52,52]],[[52,52],52],[[52,52],22],[[]],[[]],[[]],[[]],[[]],[21],[[]],[52,22],[52,22],[51,22],[21,15],[[49,38,34,52]],[[52,52],22],[[],49],[29,21],[[34,52],51],[53,20],[52,52],[[52,52],[[20,[23]]]],[51,34],[51,22],[[52,52]],0,[[52,52,22]],[[52,52],52],[[52,52]],[[52,52],52],[[]],[[]],[[52,52]],[49,15],[[49,38],[[20,[51]]]],[[49,37],[[20,[36]]]],[[15,28,15],29],[15],[15],[[15,28],35],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],[[],6],[[],6],[[52,52],52],[[49,38]],[51,22],0,0,0,0,0,0,0,0,0,[[],15],[15],[[15,15,15,15],15],[15],[[],1],0,0,0,0,[[]],[[]],[14,54],[[]],0,[[]],[[],14],[[],5],[[],5],[[],6],0,0,0,0,0,0,0,0,0,0,0,0,0,[15,55],[15,55],[[28,2],55],[[15,28,15],55],[[15,28,15],55],[28,55],[16,1],[[],55],[[],55],[[],55],[[55,16],55],[[],55],0,0,0,0,0,0,0,0,0,0,[[]],[[[12,[56]]]],[[]],[[]],0,0,0,[[],[[20,[[12,[56]]]]]],[[],57],[[],15],[58,12],[16],[[],[[20,[[12,[56]]]]]],[[]],0,[[]],0,0,0,[[],59],0,0,0,0,[[]],0,[60],0,[[]],0,[[],[[20,[[12,[56]]]]]],0,[[],5],[[],5],[[],6],0,[[]],[[]],[[]],[15,60],[[]],0,0,0,[[],5],[[],5],[[],6],[[],60],0,0,0,[[61,[12,[56]]]],[[[12,[56]]]],[[]],[[]],[[]],[[]],[62,14],[61,[[20,[[12,[56]]]]]],[[],[[20,[[12,[56]]]]]],[[]],[[]],[[]],[[]],[[],61],0,[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],0,0,0,0,0,0,[63,59],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,[[63,15]],[64,14],[59],[65],[[]],[[]],[[]],[[]],[65,15],[[]],[[]],[[]],[[]],[15],[[],63],[59,65],0,[[],59],[65],0,[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],[[],6],0,0,0,[[]],[[]],[[]],[[]],[66,[[20,[[12,[56]]]]]],0,[[],[[20,[[12,[56]]]]]],[[],57],[[],15],[67,14],[[]],[[]],[66,60],0,[[]],[[]],[[],66],[[]],[60],[66,[[20,[[12,[56]]]]]],[[],[[20,[[12,[56]]]]]],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],0,0,0,0,0,0,0,[68,15],0,[[]],[[]],[[]],[[]],[[]],[[]],0,[69,69],[[]],[[69,69],22],[56],0,0,[12,[[12,[56]]]],[[]],[[]],[[]],[68,69],[68,57],[68,15],[56,15],0,[56,[[54,[68]]]],[[]],[[]],[[]],[68,22],0,0,[[],56],0,0,0,0,[[]],0,[[],5],[[],5],[[],5],[[],5],[[],5],[[],5],[[],6],[[],6],[[],6],0,0,[[],15],[[],15],[[]],0,0,[[]],[[]],0,0,0,[[]],[[]],0,[[],1],[[],1],0,[[],1],0,0,[[15,15,15,15,15],57],[[]],[[]],[[57,26],10],[[]],[[]],0,0,0,[[57,15]],0,0,[[],5],[[],5],[[],6],0],"p":[[15,"never"],[15,"u32"],[3,"RISCV64"],[15,"u64"],[4,"Result"],[3,"TypeId"],[3,"Arguments"],[3,"Stdout"],[15,"str"],[6,"Result"],[3,"BLOCK_DEVICE"],[3,"Arc"],[3,"QUEUE_FRAMES"],[3,"UPSafeCell"],[15,"usize"],[15,"i32"],[3,"VirtIOBlock"],[3,"OpenFlags"],[3,"OSInode"],[4,"Option"],[3,"UserBuffer"],[15,"bool"],[4,"Ordering"],[3,"ROOT_INODE"],[8,"IntoIterator"],[3,"Formatter"],[3,"Inode"],[15,"u8"],[3,"Vec"],[3,"Stdin"],[3,"Stdout"],[3,"PanicInfo"],[3,"FrameTracker"],[3,"PhysPageNum"],[3,"String"],[3,"PhysAddr"],[3,"VirtAddr"],[3,"VirtPageNum"],[8,"Clone"],[3,"SimpleRange"],[3,"SimpleRangeIterator"],[3,"StackFrameAllocator"],[3,"FRAME_ALLOCATOR"],[3,"Layout"],[3,"MemorySet"],[3,"MapPermission"],[4,"MapType"],[3,"MapArea"],[3,"PageTable"],[3,"KERNEL_SPACE"],[3,"PageTableEntry"],[3,"PTEFlags"],[3,"UserBufferIterator"],[3,"RefMut"],[15,"isize"],[3,"TaskControlBlock"],[3,"TrapContext"],[3,"INITPROC"],[3,"PidHandle"],[3,"TaskContext"],[3,"TaskManager"],[3,"TASK_MANAGER"],[3,"PidAllocator"],[3,"PID_ALLOCATOR"],[3,"KernelStack"],[3,"Processor"],[3,"PROCESSOR"],[3,"TaskControlBlockInner"],[4,"TaskStatus"],[8,"QEMUExit"],[3,"VirtioHal"],[8,"File"],[3,"OSInodeInner"],[8,"StepByOne"],[8,"FrameAllocator"]]}\
+"os":{"doc":"The main module and entrypoint","t":[0,5,0,0,0,0,0,0,14,14,5,0,0,0,0,0,0,6,17,17,17,2,17,17,2,2,17,17,17,17,17,3,11,11,11,11,5,11,11,11,11,2,2,0,3,2,12,5,11,11,11,11,11,11,11,11,0,12,3,17,3,3,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,8,3,3,3,3,12,12,0,5,5,10,10,12,0,10,12,10,18,3,3,3,18,18,3,18,18,12,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,5,11,11,11,12,5,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,3,3,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,5,12,12,12,12,3,3,3,3,3,3,3,3,8,3,3,3,3,12,0,12,12,12,12,12,12,12,5,0,5,12,0,5,5,0,0,12,12,5,12,10,5,5,5,5,12,12,12,12,17,17,3,3,3,3,8,17,6,17,3,3,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,12,10,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,3,8,6,3,3,12,10,11,11,11,11,11,11,11,12,10,11,11,11,12,11,5,5,5,11,11,11,11,5,11,11,11,10,11,11,12,12,11,11,11,11,11,11,11,11,11,7,7,5,5,5,13,13,3,3,3,4,3,18,18,18,18,12,11,11,12,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,5,5,5,11,11,11,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,5,11,11,12,11,12,11,11,11,11,11,12,11,11,11,5,11,11,5,5,11,5,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,18,18,18,3,3,3,18,18,3,3,18,18,18,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,5,5,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,5,5,5,5,3,12,0,3,11,11,11,11,12,11,11,11,11,11,17,17,17,17,17,17,17,17,17,17,17,0,0,5,5,5,5,5,5,5,5,5,5,5,5,12,17,3,3,3,3,3,3,3,12,5,5,11,11,0,12,12,5,5,5,11,5,5,11,12,11,0,0,12,5,0,12,12,12,5,12,5,12,5,0,5,0,11,11,11,3,11,11,11,11,11,12,12,12,11,11,11,11,3,3,12,11,5,11,11,11,11,11,11,5,11,11,11,11,11,12,11,11,11,11,11,11,12,3,3,3,3,12,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,5,11,11,12,5,11,12,11,11,11,11,11,11,11,11,11,11,11,11,3,3,12,11,11,11,11,11,12,5,5,5,11,11,11,11,12,11,11,11,5,5,11,5,11,11,11,11,11,11,5,13,13,3,3,4,13,11,12,11,11,11,11,11,11,12,11,11,11,11,12,12,11,11,11,11,11,11,11,11,12,11,11,11,11,11,12,12,11,12,12,12,12,11,12,11,11,11,11,11,11,11,11,11,17,17,5,5,5,3,0,5,5,12,12,12,5,5,12,5,5,12,5,12,3,11,11,11,11,11,11,12,12,12,11,12,12,11,11,11,12],"n":["board","clear_bss","config","console","drivers","fs","lang_items","mm","print","println","rust_main","sbi","sync","syscall","task","timer","trap","BlockDeviceImpl","CLOCK_FREQ","MEMORY_END","MMIO","CLOCK_FREQ","KERNEL_HEAP_SIZE","KERNEL_STACK_SIZE","MEMORY_END","MMIO","PAGE_SIZE","PAGE_SIZE_BITS","TRAMPOLINE","TRAP_CONTEXT","USER_STACK_SIZE","Stdout","borrow","borrow_mut","from","into","print","try_from","try_into","type_id","write_str","BLOCK_DEVICE","BLOCK_DEVICE","block","BLOCK_DEVICE","VirtIOBlock","__private_field","block_device_test","borrow","borrow_mut","deref","from","into","try_from","try_into","type_id","virtio_blk","0","QUEUE_FRAMES","VIRTIO0","VirtIOBlock","VirtioHal","__private_field","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","deref","dma_alloc","dma_dealloc","from","from","from","into","into","into","new","phys_to_virt","read_block","try_from","try_from","try_from","try_into","try_into","try_into","type_id","type_id","type_id","virt_to_phys","write_block","File","OSInode","OpenFlags","Stdin","Stdout","bits","inner","inode","list_apps","open_file","read","readable","readable","stdio","writable","writable","write","CREATE","OSInode","OSInodeInner","OpenFlags","RDONLY","RDWR","ROOT_INODE","TRUNC","WRONLY","__private_field","all","bitand","bitand_assign","bitor","bitor_assign","bits","bits","bitxor","bitxor_assign","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone_into","cmp","complement","contains","deref","difference","empty","eq","extend","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from_bits","from_bits_truncate","from_bits_unchecked","from_iter","hash","inner","inode","insert","intersection","intersects","into","into","into","into","is_all","is_empty","list_apps","ne","new","not","offset","open_file","partial_cmp","read","read_all","read_write","readable","readable","remove","set","sub","sub_assign","symmetric_difference","to_owned","toggle","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","union","writable","writable","write","Stdin","Stdout","borrow","borrow","borrow_mut","borrow_mut","from","from","into","into","read","read","readable","readable","try_from","try_from","try_into","try_into","type_id","type_id","writable","writable","write","write","panic","0","0","0","0","FrameTracker","KERNEL_SPACE","MapPermission","MemorySet","PageTable","PageTableEntry","PhysAddr","PhysPageNum","StepByOne","UserBuffer","UserBufferIterator","VirtAddr","VirtPageNum","__private_field","address","areas","bits","bits","buffers","buffers","current_buffer","current_idx","frame_alloc","frame_allocator","frame_dealloc","frames","heap_allocator","init","kernel_token","memory_set","page_table","page_table","ppn","remap_test","root_ppn","step","translated_byte_buffer","translated_ref","translated_refmut","translated_str","0","0","0","0","PA_WIDTH_SV39","PPN_WIDTH_SV39","PhysAddr","PhysPageNum","SimpleRange","SimpleRangeIterator","StepByOne","VA_WIDTH_SV39","VPNRange","VPN_WIDTH_SV39","VirtAddr","VirtPageNum","aligned","aligned","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","ceil","ceil","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","cmp","cmp","cmp","cmp","current","end","eq","eq","eq","eq","floor","floor","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","from","from","from","from","from","get_bytes_array","get_end","get_mut","get_mut","get_pte_array","get_ref","get_start","indexes","into","into","into","into","into","into","into_iter","into_iter","l","ne","ne","ne","ne","new","new","next","page_offset","page_offset","partial_cmp","partial_cmp","partial_cmp","partial_cmp","r","step","step","step","to_owned","to_owned","to_owned","to_owned","to_owned","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","FRAME_ALLOCATOR","FrameAllocator","FrameAllocatorImpl","FrameTracker","StackFrameAllocator","__private_field","alloc","alloc","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","current","dealloc","dealloc","deref","drop","end","fmt","frame_alloc","frame_allocator_test","frame_dealloc","from","from","from","init","init_frame_allocator","into","into","into","new","new","new","ppn","recycled","try_from","try_from","try_from","try_into","try_into","try_into","type_id","type_id","type_id","HEAP_ALLOCATOR","HEAP_SPACE","handle_alloc_error","heap_test","init_heap","Framed","Identical","KERNEL_SPACE","MapArea","MapPermission","MapType","MemorySet","R","U","W","X","__private_field","activate","all","areas","bitand","bitand_assign","bitor","bitor_assign","bits","bits","bitxor","bitxor_assign","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone","clone_into","clone_into","cmp","complement","contains","copy_data","data_frames","deref","difference","ebss","edata","ekernel","empty","eq","eq","erodata","etext","extend","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from_another","from_bits","from_bits_truncate","from_bits_unchecked","from_elf","from_existed_user","from_iter","hash","insert","insert_framed_area","intersection","intersects","into","into","into","into","into","is_all","is_empty","kernel_token","map","map_one","map_perm","map_trampoline","map_type","ne","new","new_bare","new_kernel","not","page_table","partial_cmp","push","recycle_data_pages","remap_test","remove","remove_area_with_start_vpn","sbss_with_stack","sdata","set","srodata","stext","strampoline","sub","sub_assign","symmetric_difference","to_owned","to_owned","toggle","token","translate","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","union","unmap","unmap_one","vpn_range","A","D","G","PTEFlags","PageTable","PageTableEntry","R","U","UserBuffer","UserBufferIterator","V","W","X","all","bitand","bitand_assign","bitor","bitor_assign","bits","bits","bits","bitxor","bitxor_assign","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","buffers","buffers","clone","clone","clone_into","clone_into","cmp","complement","contains","current_buffer","current_idx","difference","empty","empty","eq","executable","extend","find_pte","find_pte_create","flags","fmt","fmt","fmt","fmt","fmt","frames","from","from","from","from","from","from_bits","from_bits_truncate","from_bits_unchecked","from_iter","from_token","hash","insert","intersection","intersects","into","into","into","into","into","into_iter","into_iter","is_all","is_empty","is_valid","len","map","ne","new","new","new","next","not","partial_cmp","ppn","readable","remove","root_ppn","set","sub","sub_assign","symmetric_difference","to_owned","to_owned","toggle","token","translate","translate_va","translated_byte_buffer","translated_ref","translated_refmut","translated_str","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","union","unmap","writable","console_getchar","console_putchar","set_timer","shutdown","UPSafeCell","inner","up","UPSafeCell","borrow","borrow_mut","exclusive_access","from","inner","into","new","try_from","try_into","type_id","SYSCALL_CLOSE","SYSCALL_EXEC","SYSCALL_EXIT","SYSCALL_FORK","SYSCALL_GETPID","SYSCALL_GET_TIME","SYSCALL_OPEN","SYSCALL_READ","SYSCALL_WAITPID","SYSCALL_WRITE","SYSCALL_YIELD","fs","process","syscall","sys_close","sys_open","sys_read","sys_write","sys_exec","sys_exit","sys_fork","sys_get_time","sys_getpid","sys_waitpid","sys_yield","0","IDLE_PID","INITPROC","KernelStack","PidAllocator","PidHandle","Processor","TaskContext","TaskManager","__private_field","add_initproc","add_task","borrow","borrow_mut","context","current","current","current_task","current_trap_cx","current_user_token","deref","exit_current_and_run_next","fetch_task","from","idle_task_cx","into","manager","pid","pid","pid_alloc","processor","ra","ready_queue","recycled","run_tasks","s","schedule","sp","suspend_current_and_run_next","switch","take_current_task","task","try_from","try_into","type_id","TaskContext","borrow","borrow_mut","from","goto_trap_return","into","ra","s","sp","try_from","try_into","type_id","zero_init","TASK_MANAGER","TaskManager","__private_field","add","add_task","borrow","borrow","borrow_mut","borrow_mut","deref","fetch","fetch_task","from","from","into","into","new","ready_queue","try_from","try_from","try_into","try_into","type_id","type_id","0","KernelStack","PID_ALLOCATOR","PidAllocator","PidHandle","__private_field","alloc","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","current","dealloc","deref","drop","drop","from","from","from","from","get_top","into","into","into","into","kernel_stack_position","new","new","pid","pid_alloc","push_on_top","recycled","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","PROCESSOR","Processor","__private_field","borrow","borrow","borrow_mut","borrow_mut","current","current","current_task","current_trap_cx","current_user_token","deref","from","from","get_idle_task_cx_ptr","idle_task_cx","into","into","new","run_tasks","schedule","take_current","take_current_task","try_from","try_from","try_into","try_into","type_id","type_id","__switch","Ready","Running","TaskControlBlock","TaskControlBlockInner","TaskStatus","Zombie","alloc_fd","base_size","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","children","clone","clone_into","eq","exec","exit_code","fd_table","fork","from","from","from","get_status","get_trap_cx","get_user_token","getpid","inner","inner_exclusive_access","into","into","into","is_zombie","kernel_stack","memory_set","new","parent","pid","task_cx","task_status","to_owned","trap_cx_ppn","try_from","try_from","try_from","try_into","try_into","try_into","type_id","type_id","type_id","MSEC_PER_SEC","TICKS_PER_SEC","get_time","get_time_ms","set_next_trigger","TrapContext","context","enable_timer_interrupt","init","kernel_satp","kernel_sp","sepc","set_kernel_trap_entry","set_user_trap_entry","sstatus","trap_from_kernel","trap_handler","trap_handler","trap_return","x","TrapContext","app_init_context","borrow","borrow_mut","fmt","from","into","kernel_satp","kernel_sp","sepc","set_sp","sstatus","trap_handler","try_from","try_into","type_id","x"],"q":["os","","","","","","","","","","","","","","","","","os::board","","","","os::config","","","","","","","","","","os::console","","","","","","","","","","os::drivers","","","os::drivers::block","","","","","","","","","","","","","os::drivers::block::virtio_blk","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::fs","","","","","","","","","","","","","","","","","os::fs::inode","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::fs::stdio","","","","","","","","","","","","","","","","","","","","","","","","os::lang_items","os::mm","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::address","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::frame_allocator","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::heap_allocator","","","","","os::mm::memory_set","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::mm::page_table","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::sbi","","","","os::sync","","","os::sync::up","","","","","","","","","","","os::syscall","","","","","","","","","","","","","","os::syscall::fs","","","","os::syscall::process","","","","","","","os::task","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::task::context","","","","","","","","","","","","","os::task::manager","","","","","","","","","","","","","","","","","","","","","","","","os::task::pid","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::task::processor","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::task::switch","os::task::task","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","os::timer","","","","","os::trap","","","","","","","","","","","","","","","os::trap::context","","","","","","","","","","","","","","","",""],"d":["","clear BSS segment","Constants used in rCore","SBI console driver, for text output","","File system in os","The panic handler","Memory management implementation","print string macro","println string macro","the rust entry-point of os","SBI call wrappers","Synchronization and interior mutability primitives","Implementation of syscalls","Task management implementation","RISC-V timer-related functionality","Trap handling functionality","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","Returns the argument unchanged.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","","","","","File trait","A wrapper around a filesystem inode to implement File …","Open file flags","Standard input","Standard output","","","
Arc<Inode>
->
OSInodeInner
: In order to open files …","List all files in the filesystems","Open file with flags","Read file to
UserBuffer
","If readable","","Stdin & Stdout","If writable","","Write
UserBuffer
to file","Allow create","A wrapper around a filesystem inode to implement File …","The OS inode inner in ‘UPSafeCell’","Open file flags","Read only","Read & Write","","Clear file and return an empty one","Write only","","Returns the set containing all flags.","Returns the intersection between the two sets of flags.","Disables all flags disabled in the set.","Returns the union of the two sets of flags.","Adds the set of flags.","Returns the raw value of the flags currently stored.","","Returns the left flags, but with all the right flags …","Toggles the set of flags.","","","","","","","","","","","","Returns the complement of this set of flags.","Returns
true
if all of the flags in
other
are contained …","","Returns the difference between the flags in
self
and
other
.","Returns an empty set of flags.","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Convert from underlying bit representation, unless that …","Convert from underlying bit representation, dropping any …","Convert from underlying bit representation, preserving all …","","","","","Inserts the specified flags in-place.","Returns the intersection between the flags in
self
and …","Returns
true
if there are flags common to both
self
and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Returns
true
if all flags are currently set.","Returns
true
if no flags are currently stored.","List all files in the filesystems","","Construct an OS inode from a inode","Returns the complement of this set of flags.","","Open file with flags","","","Read all data inside a inode into vector","Do not check validity for simplicity Return (readable, …","","","Removes the specified flags in-place.","Inserts or removes the specified flags depending on the …","Returns the set difference of the two sets of flags.","Disables all flags enabled in the set.","Returns the symmetric difference between the flags in
self
…","","Toggles the specified flags in-place.","","","","","","","","","","","","","Returns the union of between the flags in
self
and
other
.","","","","Standard input","Standard output","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","","","","","manage a frame which has the same lifecycle as the tracker","a memory set instance through lazy_static! managing kernel …","map permission corresponding to that in pte:
R W X U
","memory set structure, controls virtual-memory space","Record root ppn and has the same lifetime as 1 and 2 level …","page table entry structure","Definitions","phiscal page number","Add value by one","Array of u8 slice that user communicate with os","Iterator of
UserBuffer
","virtual address","virtual page number","","Implementation of physical and virtual address and page …","","","PTE","U8 vec","","","","allocate a frame","Implementation of
FrameAllocator
which controls all the …","deallocate a frame","","The global allocator","initiate heap allocator, frame allocator and kernel space","Get kernelspace root ppn","Implementation of
MapArea
and
MemorySet
.","Implementation of
PageTableEntry
and
PageTable
.","","","Check PageTable running correctly","","Add value by one","Translate a pointer to a mutable u8 Vec through page table","Translate a generic through page table and return a …","Translate a generic through page table and return a …","Translate a pointer to a mutable u8 Vec end with
\\\\0
…","","","","","","","Definitions","phiscal page number","a simple range structure for type T","iterator for the simple range structure","Add value by one","","a simple range structure for virtual page number","","virtual address","virtual page number","Check page aligned","Check page aligned","","","","","","","","","","","","","
PhysAddr
->
PhysPageNum
","
VirtAddr
->
VirtPageNum
","","","","","","","","","","","","","","","","","","","","","
PhysAddr
->
PhysPageNum
","
VirtAddr
->
VirtPageNum
","","","","","Returns the argument unchanged.","","","Returns the argument unchanged.","","","Returns the argument unchanged.","Returns the argument unchanged.","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Get u8 array on
PhysPageNum
","","Get mutable reference to
PhysAddr
value","Get Get mutable reference to
PhysAddr
value on
PhysPageNum
","Get
PageTableEntry
on
PhysPageNum
","Get reference to
PhysAddr
value","","Return VPN 3 level index","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","Get page offset","Get page offset","","","","","","Add value by one","","","","","","","","","","","","","","","","","","","","","","","","","","frame allocator instance through lazy_static!","","","manage a frame which has the same lifecycle as the tracker","an implementation for frame allocator","","","","","","","","","","","","","","","","","allocate a frame","a simple test for frame allocator","deallocate a frame","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","initiate the frame allocator using
ekernel
and
MEMORY_END
","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","Create an empty
FrameTracker
","","","","","","","","","","","","","heap allocator instance","heap space ([u8; KERNEL_HEAP_SIZE])","panic when heap allocation error occurs","","initiate heap allocator","","","a memory set instance through lazy_static! managing kernel …","map area structure, controls a contiguous piece of virtual …","map permission corresponding to that in pte:
R W X U
","map type for memory set: identical or framed","memory set structure, controls virtual-memory space","Readable","Accessible in U mode","Writable","Excutable","","Refresh TLB with
sfence.vma
","Returns the set containing all flags.","","Returns the intersection between the two sets of flags.","Disables all flags disabled in the set.","Returns the union of the two sets of flags.","Adds the set of flags.","Returns the raw value of the flags currently stored.","","Returns the left flags, but with all the right flags …","Toggles the set of flags.","","","","","","","","","","","","","","","","Returns the complement of this set of flags.","Returns
true
if all of the flags in
other
are contained …","data: start-aligned but maybe with shorter length assume …","","","Returns the difference between the flags in
self
and
other
.","","","","Returns an empty set of flags.","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","Convert from underlying bit representation, unless that …","Convert from underlying bit representation, dropping any …","Convert from underlying bit representation, preserving all …","Include sections in elf and trampoline and TrapContext and …","Clone a same
MemorySet
","","","Inserts the specified flags in-place.","Assume that no conflicts.","Returns the intersection between the flags in
self
and …","Returns
true
if there are flags common to both
self
and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Returns
true
if all flags are currently set.","Returns
true
if no flags are currently stored.","Get kernelspace root ppn","","","","Mention that trampoline is not collected by areas.","","","","Create an empty
MemorySet
","Without kernel stacks.","Returns the complement of this set of flags.","","","","Remove all
MapArea
","Check PageTable running correctly","Removes the specified flags in-place.","Remove
MapArea
that starts with
start_vpn
","","","Inserts or removes the specified flags depending on the …","","","","Returns the set difference of the two sets of flags.","Disables all flags enabled in the set.","Returns the symmetric difference between the flags in
self
…","","","Toggles the specified flags in-place.","Get pagetable
root_ppn
","Translate throuth pagetable","","","","","","","","","","","","","","","","Returns the union of between the flags in
self
and
other
.","","","","","","","","Record root ppn and has the same lifetime as 1 and 2 level …","page table entry structure","","","Array of u8 slice that user communicate with os","Iterator of
UserBuffer
","","","","Returns the set containing all flags.","Returns the intersection between the two sets of flags.","Disables all flags disabled in the set.","Returns the union of the two sets of flags.","Adds the set of flags.","Returns the raw value of the flags currently stored.","","PTE","Returns the left flags, but with all the right flags …","Toggles the set of flags.","","","","","","","","","","","U8 vec","","","","","","","Returns the complement of this set of flags.","Returns
true
if all of the flags in
other
are contained …","","","Returns the difference between the flags in
self
and
other
.","Returns an empty set of flags.","Return an empty PTE","","Check PTE executable","","Find phsical address by virtual address","Find phsical address by virtual address, create a frame if …","Return 10bit flag","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Convert from underlying bit representation, unless that …","Convert from underlying bit representation, dropping any …","Convert from underlying bit representation, preserving all …","","Temporarily used to get arguments from user space.","","Inserts the specified flags in-place.","Returns the intersection between the flags in
self
and …","Returns
true
if there are flags common to both
self
and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","Returns
true
if all flags are currently set.","Returns
true
if no flags are currently stored.","Check PTE valid","Length of
UserBuffer
","Create a mapping form
vpn
to
ppn
","","Create an empty
PageTable
","Create a
UserBuffer
by parameter","Create a PTE from ppn","","Returns the complement of this set of flags.","","Return 44bit ppn","Check PTE readable","Removes the specified flags in-place.","","Inserts or removes the specified flags depending on the …","Returns the set difference of the two sets of flags.","Disables all flags enabled in the set.","Returns the symmetric difference between the flags in
self
…","","","Toggles the specified flags in-place.","Get root ppn","Translate
VirtPageNum
to
PageTableEntry
","Translate
VirtAddr
to
PhysAddr
","Translate a pointer to a mutable u8 Vec through page table","Translate a generic through page table and return a …","Translate a generic through page table and return a …","Translate a pointer to a mutable u8 Vec end with
\\\\0
…","","","","","","","","","","","","","","","","Returns the union of between the flags in
self
and
other
.","Delete a mapping form
vpn
","Check PTE writable","use sbi call to getchar from console (qemu uart handler)","use sbi call to putchar in console (qemu uart handler)","use sbi call to set timer","use sbi call to shutdown the kernel","Wrap a static data structure inside it so that we are able …","inner data","Uniprocessor interior mutability primitives","Wrap a static data structure inside it so that we are able …","","","Exclusive access inner data in UPSafeCell. Panic if the …","Returns the argument unchanged.","inner data","Calls
U::from(self)
.","User is responsible to guarantee that inner struct is only …","","","","","","","","","","","","","","","File and filesystem-related syscalls","","handle syscall exception with
syscall_id
and other …","","","","","","","","","","If there is not a child process whose pid is same as …","","","pid of usertests app in make run TEST=1","Globle process that init user shell","Kernelstack for app","Pid Allocator struct","Bind pid lifetime to
PidHandle
","Processor management structure","task context structure containing some registers","A array of
TaskControlBlock
that is thread-safe","","Add init process to the manager","Interface offered to add task","","","Implementation of
TaskContext
","","The task currently executing on the current processor","Get running task","Get the mutable reference to trap context of current task","Get token of the address space of current task","","Exit the current ‘Running’ task and run the next task …","Interface offered to pop the first task","Returns the argument unchanged.","The basic control flow of each core, helping to select and …","Calls
U::from(self)
.","Implementation of
TaskManager
","Implementation of
PidAllocator
","","Allocate a pid from PID_ALLOCATOR","Implementation of
Processor
and Intersection of control …","return address ( e.g. __restore ) of __switch ASM function","","","The main part of process execution and scheduling Loop …","s0-11 register, callee saved","Return to idle control flow for new scheduling","kernel stack pointer of app","Suspend the current ‘Running’ task and run the next …","Wrap
switch.S
as a function","Take the current task,leaving a None in its place","Implementation of
TaskControlBlock
","","","","task context structure containing some registers","","","Returns the argument unchanged.","set Task Context{__restore ASM funciton: trap_return, sp: …","Calls
U::from(self)
.","return address ( e.g. __restore ) of __switch ASM function","s0-11 register, callee saved","kernel stack pointer of app","","","","init task context","","A array of
TaskControlBlock
that is thread-safe","","Add a task to
TaskManager
","Interface offered to add task","","","","","","Remove the first task and return it,or
None
if
TaskManager
…","Interface offered to pop the first task","Returns the argument unchanged.","Returns the argument unchanged.","Calls
U::from(self)
.","Calls
U::from(self)
.","Creat an empty TaskManager","","","","","","","","","Kernelstack for app","","Pid Allocator struct","Bind pid lifetime to
PidHandle
","","Allocate a pid","","","","","","","","","","Recycle a pid","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Get the value on the top of kernelstack","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","Return (bottom, top) of a kernel stack in kernel space.","Create an empty
PidAllocator
","Create a kernelstack from pid","","Allocate a pid from PID_ALLOCATOR","Push a value on top of kernelstack","","","","","","","","","","","","","","","Processor management structure","","","","","","Get current task in cloning semanteme","The task currently executing on the current processor","Get running task","Get the mutable reference to trap context of current task","Get token of the address space of current task","","Returns the argument unchanged.","Returns the argument unchanged.","Get mutable reference to
idle_task_cx
","The basic control flow of each core, helping to select and …","Calls
U::from(self)
.","Calls
U::from(self)
.","Create an empty Processor","The main part of process execution and scheduling Loop …","Return to idle control flow for new scheduling","Get current task in moving semanteme","Take the current task,leaving a None in its place","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","","","","","Calls
U::from(self)
.","Calls
U::from(self)
.","Calls
U::from(self)
.","","","","","","","","","","","","","","","","","","","","","","get current time","get current time in microseconds","set the next timer interrupt","trap context structure containing sstatus, sepc and …","Implementation of
TrapContext
","enable timer interrupt in sie CSR","initialize CSR
stvec
as the entry of
__alltraps
","Addr of Page Table","kernel stack","CSR sepc","","","CSR sstatus ","Unimplement: traps/interrupts/exceptions from kernel mode …","handle an interrupt, exception, or system call from user …","Addr of trap_handler function","set the new addr of __restore asm function in TRAMPOLINE …","general regs[0..31]","trap context structure containing sstatus, sepc and …","init app context","","","","Returns the argument unchanged.","Calls
U::from(self)
.","Addr of Page Table","kernel stack","CSR sepc","set stack pointer to x_2 reg (sp)","CSR sstatus ","Addr of trap_handler function","","","","general regs[0..31]"],"i":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,5,5,5,5,0,5,5,5,5,0,0,0,0,0,8,0,8,8,8,8,8,8,8,8,0,14,0,0,0,0,10,14,68,10,14,68,10,10,68,68,14,68,10,14,68,10,14,68,14,14,68,10,14,68,10,14,68,10,68,14,0,0,0,0,0,15,16,0,0,0,69,69,16,0,69,16,69,15,0,0,0,15,15,0,15,15,22,15,15,15,15,15,15,15,15,15,16,70,22,15,16,70,22,15,15,15,15,15,15,22,15,15,15,15,15,15,15,15,15,16,70,22,15,15,15,15,15,15,16,70,15,15,15,16,70,22,15,15,15,0,15,16,15,70,0,15,16,16,15,16,16,15,15,15,15,15,15,15,16,70,22,15,16,70,22,15,16,70,22,15,15,16,16,16,0,0,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,0,34,35,32,36,0,0,0,0,0,0,0,0,0,0,0,0,0,48,0,43,44,49,18,51,51,51,0,0,0,47,0,0,0,0,0,43,31,0,47,71,0,0,0,0,34,35,32,36,0,0,0,0,0,0,0,0,0,0,0,0,34,35,39,34,35,32,36,38,39,34,35,32,36,38,34,35,34,35,32,36,38,34,35,32,36,38,34,35,32,36,39,39,34,35,32,36,34,35,34,35,32,36,39,34,34,34,35,35,35,32,32,32,36,36,36,38,32,38,34,32,32,34,38,36,39,34,35,32,36,38,39,38,38,34,35,32,36,39,38,39,34,35,34,35,32,36,38,71,32,36,34,35,32,36,38,39,34,35,32,36,38,39,34,35,32,36,38,39,34,35,32,36,38,0,0,0,0,0,41,72,40,31,40,41,31,40,41,40,72,40,41,31,40,31,0,0,0,31,40,41,40,0,31,40,41,72,31,40,31,40,31,40,41,31,40,41,31,40,41,0,0,0,0,0,45,45,0,0,0,0,0,44,44,44,44,48,43,44,43,44,44,44,44,44,44,44,44,43,46,48,45,44,43,46,48,45,44,45,44,45,44,44,44,44,46,46,48,44,0,0,0,44,45,44,0,0,44,45,44,44,44,44,44,43,46,48,45,44,46,44,44,44,43,43,44,44,44,43,44,44,43,46,48,45,44,44,44,0,46,46,46,43,46,44,46,43,43,44,43,44,43,43,0,44,43,0,0,44,0,0,0,44,44,44,45,44,44,43,43,43,46,48,45,44,43,46,48,45,44,43,46,48,45,44,44,46,46,46,50,50,50,0,0,0,50,50,0,0,50,50,50,50,50,50,50,50,50,50,49,50,50,47,18,51,50,49,47,18,51,50,49,18,51,50,49,50,49,50,50,50,51,51,50,50,49,50,49,50,47,47,49,50,50,50,50,50,47,47,18,51,50,49,50,50,50,50,47,50,50,50,50,47,18,51,50,49,18,51,50,50,49,18,47,50,47,18,49,51,50,50,49,49,50,47,50,50,50,50,50,49,50,47,47,47,0,0,0,0,47,18,51,50,49,47,18,51,50,49,47,18,51,50,49,50,47,49,0,0,0,0,0,11,0,0,11,11,11,11,11,11,11,11,11,11,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,57,0,0,0,0,0,0,0,0,56,0,0,56,56,0,61,64,0,0,0,56,0,0,56,64,56,0,0,63,0,0,58,59,61,0,58,0,58,0,0,0,0,56,56,56,0,58,58,58,58,58,58,58,58,58,58,58,58,0,0,60,59,0,59,60,59,60,60,59,0,59,60,59,60,59,59,59,60,59,60,59,60,57,0,0,0,0,62,61,61,57,63,62,61,57,63,62,61,61,62,57,63,61,57,63,62,63,61,57,63,62,0,61,63,63,0,63,61,61,57,63,62,61,57,63,62,61,57,63,62,0,0,65,64,65,64,65,64,64,0,0,0,65,64,65,64,64,64,65,64,0,0,64,0,64,65,64,65,64,65,0,67,67,0,0,0,67,66,66,54,66,67,54,66,67,66,67,67,67,54,66,66,54,54,66,67,66,66,66,54,54,54,54,66,67,66,54,66,54,66,54,66,66,67,66,54,66,67,54,66,67,54,66,67,0,0,0,0,0,0,0,0,0,55,55,55,0,0,55,0,0,55,0,55,0,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55],"f":[0,[[]],0,0,0,0,0,0,0,0,[[],1],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[]],[[]],[[]],[[]],[2],[[],3],[[],3],[[],4],[[5,6],7],0,0,0,0,0,0,[[]],[[]],[[]],[8,9],[[]],[[]],[[],3],[[],3],[[],4],0,0,0,0,0,0,0,[[]],[[]],[[]],[[]],[[]],[[]],[10,11],[12,12],[[12,12],13],[[]],[[]],[[]],[[]],[[]],[[]],[[],14],[12,12],[[14,12]],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],[12,12],[[14,12]],0,0,0,0,0,0,0,0,[[]],[[6,15],[[17,[[9,[16]]]]]],[18,12],[[],19],0,0,[[],19],0,[18,12],0,0,0,0,0,0,0,0,0,0,[[],15],[[15,15],15],[[15,15]],[[15,15],15],[[15,15]],[15,20],0,[[15,15],15],[[15,15]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[15,15],[[]],[[15,15],21],[15,15],[[15,15],19],[22,9],[[15,15],15],[[],15],[[15,15],19],[[15,23]],[[15,24],7],[[15,24],7],[[15,24],7],[[15,24],7],[[15,24],7],[[]],[[]],[[]],[[]],[20,[[17,[15]]]],[20,15],[20,15],[23,15],[15],0,0,[[15,15]],[[15,15],15],[[15,15],19],[[]],[[]],[[]],[[]],[15,19],[15,19],[[]],[[15,15],19],[[19,19,[9,[25]]],16],[15,15],0,[[6,15],[[17,[[9,[16]]]]]],[[15,15],[[17,[21]]]],[[16,18],12],[16,[[27,[26]]]],[15],[16,19],0,[[15,15]],[[15,15,19]],[[15,15],15],[[15,15]],[[15,15],15],[[]],[[15,15]],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],[[],4],[[15,15],15],[16,19],0,[[16,18],12],0,0,[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[28,18],12],[[29,18],12],[28,19],[29,19],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[28,19],[29,19],[[28,18],12],[[29,18],12],[30,1],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[],[[17,[31]]]],0,[32],0,0,[[]],[[],12],0,0,0,0,[[]],0,[[]],[[12,26,12],27],[12],[12],[[12,26],33],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[34,19],[35,19],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[34,32],[35,36],[34,34],[35,35],[32,32],[36,36],[[[38,[37]]],[[38,[37]]]],[[]],[[]],[[]],[[]],[[]],[[34,34],21],[[35,35],21],[[32,32],21],[[36,36],21],0,0,[[34,34],19],[[35,35],19],[[32,32],19],[[36,36],19],[34,32],[35,36],[[34,24],7],[[35,24],7],[[32,24],7],[[36,24],7],[[]],[12,34],[32,34],[[]],[12,35],[36,35],[[]],[[]],[12,32],[34,32],[35,36],[12,36],[[]],[[]],[32],[38],[34],[32],[32],[34],[38],[36],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[38],0,[[34,34],19],[[35,35],19],[[32,32],19],[[36,36],19],[[],39],[[],38],[39,17],[34,12],[35,12],[[34,34],[[17,[21]]]],[[35,35],[[17,[21]]]],[[32,32],[[17,[21]]]],[[36,36],[[17,[21]]]],0,[[]],[32],[36],[[]],[[]],[[]],[[]],[[]],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],[[],4],[[],4],[[],4],0,0,0,0,0,0,[[],[[17,[32]]]],[40,[[17,[32]]]],[[]],[[]],[[]],[[]],[[]],[[]],0,[32],[[40,32]],[41,11],[31],0,[[31,24],7],[[],[[17,[31]]]],[[]],[32],[[]],[[]],[[]],[[40,32,32]],[[]],[[]],[[]],[[]],[[]],[32,31],[[],40],0,0,[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],0,0,[42,1],[[]],[[]],0,0,0,0,0,0,0,0,0,0,0,0,[43],[[],44],0,[[44,44],44],[[44,44]],[[44,44],44],[[44,44]],[44,26],0,[[44,44],44],[[44,44]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[45,45],[44,44],[[]],[[]],[[44,44],21],[44,44],[[44,44],19],[[46,47]],0,[48,9],[[44,44],44],0,0,0,[[],44],[[45,45],19],[[44,44],19],0,0,[[44,23]],[[45,24],7],[[44,24],7],[[44,24],7],[[44,24],7],[[44,24],7],[[44,24],7],[[]],[[]],[[]],[[]],[[]],[46,46],[26,[[17,[44]]]],[26,44],[26,44],[[]],[43,43],[23,44],[44],[[44,44]],[[43,35,35,44]],[[44,44],44],[[44,44],19],[[]],[[]],[[]],[[]],[[]],[44,19],[44,19],[[],12],[[46,47]],[[46,47,36]],0,[43],0,[[44,44],19],[[35,35,45,44],46],[[],43],[[],43],[44,44],0,[[44,44],[[17,[21]]]],[[43,46,17]],[43],[[]],[[44,44]],[[43,36]],0,0,[[44,44,19]],0,0,0,[[44,44],44],[[44,44]],[[44,44],44],[[]],[[]],[[44,44]],[43,12],[[43,36],[[17,[49]]]],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],[[],4],[[],4],[[44,44],44],[[46,47]],[[46,47,36]],0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[],50],[[50,50],50],[[50,50]],[[50,50],50],[[50,50]],[50,26],0,0,[[50,50],50],[[50,50]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,0,[50,50],[49,49],[[]],[[]],[[50,50],21],[50,50],[[50,50],19],0,0,[[50,50],50],[[],50],[[],49],[[50,50],19],[49,19],[[50,23]],[[47,36],[[17,[49]]]],[[47,36],[[17,[49]]]],[49,50],[[50,24],7],[[50,24],7],[[50,24],7],[[50,24],7],[[50,24],7],0,[[]],[[]],[[]],[[]],[[]],[26,[[17,[50]]]],[26,50],[26,50],[23,50],[12,47],[50],[[50,50]],[[50,50],50],[[50,50],19],[[]],[[]],[[]],[[]],[[]],[18],[[]],[50,19],[50,19],[49,19],[18,12],[[47,36,32,50]],[[50,50],19],[[],47],[27,18],[[32,50],49],[51,17],[50,50],[[50,50],[[17,[21]]]],[49,32],[49,19],[[50,50]],0,[[50,50,19]],[[50,50],50],[[50,50]],[[50,50],50],[[]],[[]],[[50,50]],[47,12],[[47,36],[[17,[49]]]],[[47,35],[[17,[34]]]],[[12,26,12],27],[12],[12],[[12,26],33],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],[[],4],[[],4],[[50,50],50],[[47,36]],[49,19],[[],12],[12],[12],[19,1],0,0,0,0,[[]],[[]],[11,52],[[]],0,[[]],[[],11],[[],3],[[],3],[[],4],0,0,0,0,0,0,0,0,0,0,0,0,0,[12,53],[12,53],[[26,20],53],[[12,26,12],53],[[12,26,12],53],[26,53],[13,1],[[],53],[[],53],[[],53],[[53,13],53],[[],53],0,0,0,0,0,0,0,0,0,0,[[]],[[[9,[54]]]],[[]],[[]],0,0,0,[[],[[17,[[9,[54]]]]]],[[],55],[[],12],[56,9],[13],[[],[[17,[[9,[54]]]]]],[[]],0,[[]],0,0,0,[[],57],0,0,0,0,[[]],0,[58],0,[[]],0,[[],[[17,[[9,[54]]]]]],0,[[],3],[[],3],[[],4],0,[[]],[[]],[[]],[12,58],[[]],0,0,0,[[],3],[[],3],[[],4],[[],58],0,0,0,[[59,[9,[54]]]],[[[9,[54]]]],[[]],[[]],[[]],[[]],[60,11],[59,[[17,[[9,[54]]]]]],[[],[[17,[[9,[54]]]]]],[[]],[[]],[[]],[[]],[[],59],0,[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],0,0,0,0,0,0,[61,57],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],0,[[61,12]],[62,11],[57],[63],[[]],[[]],[[]],[[]],[63,12],[[]],[[]],[[]],[[]],[12],[[],61],[57,63],0,[[],57],[63],0,[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],[[],4],0,0,0,[[]],[[]],[[]],[[]],[64,[[17,[[9,[54]]]]]],0,[[],[[17,[[9,[54]]]]]],[[],55],[[],12],[65,11],[[]],[[]],[64,58],0,[[]],[[]],[[],64],[[]],[58],[64,[[17,[[9,[54]]]]]],[[],[[17,[[9,[54]]]]]],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],0,0,0,0,0,0,0,[66,12],0,[[]],[[]],[[]],[[]],[[]],[[]],0,[67,67],[[]],[[67,67],19],[54],0,0,[9,[[9,[54]]]],[[]],[[]],[[]],[66,67],[66,55],[66,12],[54,12],0,[54,[[52,[66]]]],[[]],[[]],[[]],[66,19],0,0,[[],54],0,0,0,0,[[]],0,[[],3],[[],3],[[],3],[[],3],[[],3],[[],3],[[],4],[[],4],[[],4],0,0,[[],12],[[],12],[[]],0,0,[[]],[[]],0,0,0,[[]],[[]],0,[[],1],[[],1],0,[[],1],0,0,[[12,12,12,12,12],55],[[]],[[]],[[55,24],7],[[]],[[]],0,0,0,[[55,12]],0,0,[[],3],[[],3],[[],4],0],"p":[[15,"never"],[3,"Arguments"],[4,"Result"],[3,"TypeId"],[3,"Stdout"],[15,"str"],[6,"Result"],[3,"BLOCK_DEVICE"],[3,"Arc"],[3,"QUEUE_FRAMES"],[3,"UPSafeCell"],[15,"usize"],[15,"i32"],[3,"VirtIOBlock"],[3,"OpenFlags"],[3,"OSInode"],[4,"Option"],[3,"UserBuffer"],[15,"bool"],[15,"u32"],[4,"Ordering"],[3,"ROOT_INODE"],[8,"IntoIterator"],[3,"Formatter"],[3,"Inode"],[15,"u8"],[3,"Vec"],[3,"Stdin"],[3,"Stdout"],[3,"PanicInfo"],[3,"FrameTracker"],[3,"PhysPageNum"],[3,"String"],[3,"PhysAddr"],[3,"VirtAddr"],[3,"VirtPageNum"],[8,"Clone"],[3,"SimpleRange"],[3,"SimpleRangeIterator"],[3,"StackFrameAllocator"],[3,"FRAME_ALLOCATOR"],[3,"Layout"],[3,"MemorySet"],[3,"MapPermission"],[4,"MapType"],[3,"MapArea"],[3,"PageTable"],[3,"KERNEL_SPACE"],[3,"PageTableEntry"],[3,"PTEFlags"],[3,"UserBufferIterator"],[3,"RefMut"],[15,"isize"],[3,"TaskControlBlock"],[3,"TrapContext"],[3,"INITPROC"],[3,"PidHandle"],[3,"TaskContext"],[3,"TaskManager"],[3,"TASK_MANAGER"],[3,"PidAllocator"],[3,"PID_ALLOCATOR"],[3,"KernelStack"],[3,"Processor"],[3,"PROCESSOR"],[3,"TaskControlBlockInner"],[4,"TaskStatus"],[3,"VirtioHal"],[8,"File"],[3,"OSInodeInner"],[8,"StepByOne"],[8,"FrameAllocator"]]}\
}');
if (typeof window !== 'undefined' && window.initSearch) {window.initSearch(searchIndex)};
if (typeof exports !== 'undefined') {exports.searchIndex = searchIndex};
diff --git a/ch6/src/os/boards/qemu.rs.html b/ch6/src/os/boards/qemu.rs.html
index aa577d20..375373e6 100644
--- a/ch6/src/os/boards/qemu.rs.html
+++ b/ch6/src/os/boards/qemu.rs.html
@@ -7,86 +7,6 @@
7
8
9
-
10
-
11
-
12
-
13
-
14
-
15
-
16
-
17
-
18
-
19
-
20
-
21
-
22
-
23
-
24
-
25
-
26
-
27
-
28
-
29
-
30
-
31
-
32
-
33
-
34
-
35
-
36
-
37
-
38
-
39
-
40
-
41
-
42
-
43
-
44
-
45
-
46
-
47
-
48
-
49
-
50
-
51
-
52
-
53
-
54
-
55
-
56
-
57
-
58
-
59
-
60
-
61
-
62
-
63
-
64
-
65
-
66
-
67
-
68
-
69
-
70
-
71
-
72
-
73
-
74
-
75
-
76
-
77
-
78
-
79
-
80
-
81
-
82
-
83
-
84
-
85
-
86
-
87
-
88
-
89
pub const CLOCK_FREQ: usize = 12500000;
pub const MEMORY_END: usize = 0x88000000;
@@ -96,85 +16,5 @@
];
pub type BlockDeviceImpl = crate::drivers::block::VirtIOBlock;
-
-
-use core::arch::asm;
-
-const EXIT_SUCCESS: u32 = 0x5555;
-
-const EXIT_FAILURE_FLAG: u32 = 0x3333;
-const EXIT_FAILURE: u32 = exit_code_encode(1);
-const EXIT_RESET: u32 = 0x7777;
-
-pub trait QEMUExit {
-
-
-
- fn exit(&self, code: u32) -> !;
-
-
-
-
- fn exit_success(&self) -> !;
-
-
- fn exit_failure(&self) -> !;
-}
-
-
-pub struct RISCV64 {
-
- addr: u64,
-}
-
-
-const fn exit_code_encode(code: u32) -> u32 {
- (code << 16) | EXIT_FAILURE_FLAG
-}
-
-impl RISCV64 {
-
- pub const fn new(addr: u64) -> Self {
- RISCV64 { addr }
- }
-}
-
-impl QEMUExit for RISCV64 {
-
- fn exit(&self, code: u32) -> ! {
-
- let code_new = match code {
- EXIT_SUCCESS | EXIT_FAILURE | EXIT_RESET => code,
- _ => exit_code_encode(code),
- };
-
- unsafe {
- asm!(
- "sw {0}, 0({1})",
- in(reg)code_new, in(reg)self.addr
- );
-
-
-
-
-
- loop {
- asm!("wfi", options(nomem, nostack));
- }
- }
- }
-
- fn exit_success(&self) -> ! {
- self.exit(EXIT_SUCCESS);
- }
-
- fn exit_failure(&self) -> ! {
- self.exit(EXIT_FAILURE);
- }
-}
-
-const VIRT_TEST: u64 = 0x100000;
-
-pub const QEMU_EXIT_HANDLE: RISCV64 = RISCV64::new(VIRT_TEST);