Implement getloadavg()
v2: autoload PerfDataHelper functions Keep loadavg in shared memory Guard loadavg access by a mutex Initialize loadavg to the current load v3: Shared memory version bump isn't needed if we are only extending it Remove unused autoload Mark inititalized flags as NO_COPY for correct behaviour in fork child Signed-off-by: Jon Turney <jon.turney@dronecode.org.uk>
This commit is contained in:
@ -11,6 +11,7 @@ details. */
|
||||
#include "mtinfo.h"
|
||||
#include "limits.h"
|
||||
#include "mount.h"
|
||||
#include "loadavg.h"
|
||||
|
||||
#define CURR_USER_MAGIC 0xab1fcce8U
|
||||
|
||||
@ -48,6 +49,7 @@ class shared_info
|
||||
LONG last_used_bindresvport;
|
||||
DWORD obcaseinsensitive;
|
||||
mtinfo mt;
|
||||
loadavginfo loadavg;
|
||||
|
||||
void initialize ();
|
||||
void init_obcaseinsensitive ();
|
||||
|
Reference in New Issue
Block a user