summaryrefslogtreecommitdiff
path: root/Source/Library/Userland/Binding/Sys.ns.h
blob: eb09504f3f5f3fee639eb7ac84010dd4cf8b5447 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#ifndef DEF_SYS_NS_H
#define DEF_SYS_NS_H

#include <Sys.iface.h>
#include <Syscall/RessourceCaller.class.h>

namespace Sys {
	
inline void halt() {
	RessourceCaller::sCall(SYIF_IFID, SYIF_HALT);
}

inline void reboot() {
	RessourceCaller::sCall(SYIF_IFID, SYIF_REBOOT);
}

inline u32int uptime() {	//Returns uptime in seconds
	return RessourceCaller::sCall(SYIF_IFID, SYIF_UPTIME);
}

inline u32int totalRam() { 	//Returns total amount of RAM in Ko
	return RessourceCaller::sCall(SYIF_IFID, SYIF_TOTALRAM);
}

inline u32int freeRam() { 	//Returns free amount of RAM in Ko
	return RessourceCaller::sCall(SYIF_IFID, SYIF_FREERAM);
}

}

#endif