Go to the source code of this file.
|
int | Kmemcmp (const void *a, const void *b, size_t n) |
| Compare memory.
|
void * | Kmemcpy (void *dest, const void *src, unsigned int count) |
| Copy memory.
|
void | Kmemset (void *ptr, unsigned char value, unsigned int num) |
| Set memory to a value.
|
void * | Kmalloc (size_t size, size_t align) |
| Allocate memory.
|
void | KheapInit () |
| Initialize Memory Heap.
|
void | Kfree (void *ptr) |
| Free allocated memory.
|
◆ Kfree()
Free allocated memory.
- Parameters
-
voifd* | - Pointer to allocated memory (from Kmalloc) |
Definition at line 75 of file alloc.c.
◆ KheapInit()
Initialize Memory Heap.
Definition at line 35 of file alloc.c.
◆ Kmalloc()
Allocate memory.
- Parameters
-
Size | - Size of memory to allocate |
Align | - Which to align memory to |
- Returns
- Pointer to allocated memory
Definition at line 48 of file alloc.c.
◆ Kmemcmp()
int Kmemcmp |
( |
const void * | a, |
|
|
const void * | b, |
|
|
size_t | n ) |
Compare memory.
Compares the first n bytes of two memory areas.
- Parameters
-
a | Pointer to the first memory area. |
b | Pointer to the second memory area. |
n | Number of bytes to compare. |
- Returns
- An integer less than, equal to, or greater than zero if the first differing byte in a is found to be less than, equal to, or greater than the corresponding byte in b. Returns 0 if all n bytes are equal.
Definition at line 59 of file memutil.c.
◆ Kmemcpy()
void * Kmemcpy |
( |
void * | dest, |
|
|
const void * | src, |
|
|
unsigned int | count ) |
Copy memory.
- Parameters
-
void* | dest - Pointer to memory destination |
void* | src - Pointer to source memory |
u32 | count - Amount of bytes to be copied |
Definition at line 38 of file memutil.c.
◆ Kmemset()
void Kmemset |
( |
void * | ptr, |
|
|
unsigned char | value, |
|
|
unsigned int | num ) |
Set memory to a value.
- Parameters
-
void* | ptr - Pointer to memory which is to be modified |
u8 | value - Value to set memory too |
u32 | num - Number of bytes to set |
Definition at line 26 of file memutil.c.