mirror of
https://github.com/rcore-os/rCore-Tutorial-v3.git
synced 2025-01-19 05:27:13 +04:00
fix typo of sys_semaphore_create
This commit is contained in:
parent
4ad64e83f6
commit
90796450fe
@ -54,7 +54,7 @@ pub fn syscall(syscall_id: usize, args: [usize; 3]) -> isize {
|
||||
SYSCALL_MUTEX_CREATE => sys_mutex_create(args[0] == 1),
|
||||
SYSCALL_MUTEX_LOCK => sys_mutex_lock(args[0]),
|
||||
SYSCALL_MUTEX_UNLOCK => sys_mutex_unlock(args[0]),
|
||||
SYSCALL_SEMAPHORE_CREATE => sys_semaphore_creare(args[0]),
|
||||
SYSCALL_SEMAPHORE_CREATE => sys_semaphore_create(args[0]),
|
||||
SYSCALL_SEMAPHORE_UP => sys_semaphore_up(args[0]),
|
||||
SYSCALL_SEMAPHORE_DOWN => sys_semaphore_down(args[0]),
|
||||
_ => panic!("Unsupported syscall_id: {}", syscall_id),
|
||||
|
@ -53,7 +53,7 @@ pub fn sys_mutex_unlock(mutex_id: usize) -> isize {
|
||||
0
|
||||
}
|
||||
|
||||
pub fn sys_semaphore_creare(res_count: usize) -> isize {
|
||||
pub fn sys_semaphore_create(res_count: usize) -> isize {
|
||||
let process = current_process();
|
||||
let mut process_inner = process.inner_exclusive_access();
|
||||
let id = if let Some(id) = process_inner
|
||||
|
Loading…
Reference in New Issue
Block a user