31 lines
511 B
C
31 lines
511 B
C
// SPDX-License-Identifier: MIT
|
|
|
|
#include <zinnia/system.h>
|
|
#include <kernel/vdso.h>
|
|
|
|
void zn_log(const char* message, size_t len) {
|
|
zn_syscall2(message, len, ZN_SYSCALL_LOG);
|
|
}
|
|
|
|
VDSO_SYMBOL(zn_log);
|
|
|
|
size_t zn_page_size() {
|
|
size_t size = 0;
|
|
zn_syscall1(&size, ZN_SYSCALL_PAGE_SIZE);
|
|
return size;
|
|
}
|
|
|
|
VDSO_SYMBOL(zn_page_size);
|
|
|
|
zn_status_t zn_powerctl() {
|
|
return ZN_ERR_UNSUPPORTED;
|
|
}
|
|
|
|
VDSO_SYMBOL(zn_powerctl);
|
|
|
|
uint64_t zn_time() {
|
|
return vdso_data.time.nsec;
|
|
}
|
|
|
|
VDSO_SYMBOL(zn_time);
|