Skip to content

[kernel,libc] Add _fmemfree system call and wrapper functions#2106

Merged
ghaerr merged 5 commits intomasterfrom
fmemfree
Nov 18, 2024
Merged

[kernel,libc] Add _fmemfree system call and wrapper functions#2106
ghaerr merged 5 commits intomasterfrom
fmemfree

Conversation

@ghaerr
Copy link
Copy Markdown
Owner

@ghaerr ghaerr commented Nov 18, 2024

Adds the ability to free memory allocated by fmemalloc. This will likely be required for large/huge memory allocations for the JWasm port in #2103. Supports ELKS and OWC compilers/libraries.

Usage:

#include <stdlib.h>
...
    char __far *p = fmemalloc(0x10000L);  // allocate 64K of main memory
...
    fmemfree(p); // free 64k memory

Updates fmemalloc man pages in sections 2 and 3.
Also adds _HShift global for OWC huge pointer support, required in pia.asm.

@ghaerr ghaerr merged commit 6df0e7d into master Nov 18, 2024
@ghaerr ghaerr deleted the fmemfree branch November 18, 2024 20:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant