PatchworkOS
da8a090
A non-POSIX operating system.
Theme:
Default
Round
Robot
Loading...
Searching...
No Matches
munmap.c
Go to the documentation of this file.
1
#include <
stdio.h
>
2
#include <
sys/io.h
>
3
4
#include "
user/common/syscalls.h
"
5
6
void
*
munmap
(
void
*
address
,
uint64_t
length)
7
{
8
void
* result =
_syscall_munmap
(
address
, length);
9
if
(result ==
NULL
)
10
{
11
errno
=
_syscall_errno
();
12
}
13
return
result;
14
}
errno
#define errno
Error number variable.
Definition
errno.h:27
munmap
void * munmap(void *address, uint64_t length)
System call to unmap mapped memory.
Definition
munmap.c:6
NULL
#define NULL
Pointer error value.
Definition
NULL.h:23
address
static uintptr_t address
Mapped virtual address of the HPET registers.
Definition
hpet.c:95
io.h
uint64_t
__UINT64_TYPE__ uint64_t
Definition
stdint.h:17
stdio.h
syscalls.h
_syscall_errno
static errno_t _syscall_errno(void)
Definition
syscalls.h:118
_syscall_munmap
static void * _syscall_munmap(void *address, uint64_t length)
Definition
syscalls.h:198
src
libstd
user
functions
proc
munmap.c
Generated on Fri Dec 12 2025 00:22:11 for PatchworkOS by
1.9.8