diff options
Diffstat (limited to 'boot/efi/bind.c')
| -rw-r--r-- | boot/efi/bind.c | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/boot/efi/bind.c b/boot/efi/bind.c new file mode 100644 index 0000000..53522a5 --- /dev/null +++ b/boot/efi/bind.c @@ -0,0 +1,52 @@ +#include "kjarna_efi.h" + +int open(const char *path, int flags, int mode) +{ + return efi_open(path, flags, mode); +} + +int close(int fd) +{ + return efi_close(fd); +} + +off_t lseek(int fd, off_t offset, int whence) +{ + return efi_lseek(fd, offset, whence); +} + +ssize_t read(int fd, void *buffer, size_t length) +{ + return efi_read(fd, buffer, length); +} + +ssize_t write(int fd, const void *buffer, size_t length) +{ + return efi_write(fd, buffer, length); +} + +void *mmap(void *addr, size_t length, int prot, int flags, int fd, off_t offset) +{ + return efi_mmap(addr, length, prot, flags, fd, offset); +} + +int munmap(void *addr, size_t length) +{ + return efi_munmap(addr, length); +} + +void *malloc(size_t size) +{ + return efi_alloc_pool(size); +} + +void *calloc(size_t count, size_t size) +{ + return efi_calloc_pool(count, size); +} + +void free(void *block) +{ + efi_free_pool(block); +} + |
