Added a new system call sys_timer.

sys_timer accumulates timer ticks into seconds, minutes, hours and days.
It's left to the user to calculate from days into a date. It is not yet
known if the calculation is even roughly correct.

Reduced 2 kmem_reclaim/grant calls into one kmem_control call.
This commit is contained in:
Bahadir Balban
2008-04-18 00:46:29 +01:00
parent 73058dc249
commit a87914910c
12 changed files with 122 additions and 133 deletions

View File

@@ -48,8 +48,8 @@ struct kip {
u8 api_version;
u32 api_flags;
u32 kmem_reclaim;
u32 kmem_grant;
u32 kmem_control;
u32 time;
u32 space_control;
u32 thread_control;

View File

@@ -21,9 +21,9 @@
#define sys_map_offset 0x20
#define sys_getid_offset 0x24
#define sys_kread_offset 0x28
#define sys_kmem_grant_offset 0x2C
#define sys_kmem_reclaim_offset 0x30
#define syscalls_end_offset sys_kmem_reclaim_offset
#define sys_kmem_control_offset 0x2C
#define sys_time_offset 0x30
#define syscalls_end_offset sys_time_offset
#define SYSCALLS_TOTAL ((syscalls_end_offset >> 2) + 1)
int sys_ipc(struct syscall_args *);
@@ -37,7 +37,7 @@ int sys_ipc_control(struct syscall_args *);
int sys_map(struct syscall_args *);
int sys_getid(struct syscall_args *);
int sys_kread(struct syscall_args *);
int sys_kmem_grant(struct syscall_args *);
int sys_kmem_reclaim(struct syscall_args *);
int sys_kmem_control(struct syscall_args *);
int sys_time(struct syscall_args *);
#endif /* __SYSCALL_H__ */