Use implicitly passed _caller_pid in syscalls
This commit is contained in:
@ -15,7 +15,8 @@ int32_t SYSCALL2(sys_dev_gethandle, dev1, devname1) {
|
||||
int32_t ret = E_OK;
|
||||
|
||||
spinlock_acquire(&PROCS.spinlock);
|
||||
Proc *proc = PROCS.current;
|
||||
Proc *proc = NULL;
|
||||
LL_FINDPROP(PROCS.procs, proc, pid, _caller_pid);
|
||||
spinlock_release(&PROCS.spinlock);
|
||||
|
||||
char *ident = (char *)devname1;
|
||||
@ -108,7 +109,8 @@ int32_t SYSCALL4(sys_dev_cmd, dev1, cmd1, argbuf1, len1) {
|
||||
int32_t ret = E_OK;
|
||||
|
||||
spinlock_acquire(&PROCS.spinlock);
|
||||
Proc *proc = PROCS.current;
|
||||
Proc *proc = NULL;
|
||||
LL_FINDPROP(PROCS.procs, proc, pid, _caller_pid);
|
||||
spinlock_release(&PROCS.spinlock);
|
||||
|
||||
if (devh == NULL) {
|
||||
|
||||
Reference in New Issue
Block a user