vdso
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
#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);
|
||||
Reference in New Issue
Block a user