summaryrefslogtreecommitdiff
path: root/src/basic/util.h
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-06-08 20:45:32 +0200
committerLennart Poettering <lennart@poettering.net>2016-06-14 20:01:45 +0200
commitd8cf2ac79b524d7784bccb428295ebc9c5e8548c (patch)
tree43a03ab780ccc0b130dc57322c816f99e3f09754 /src/basic/util.h
parent799ec13412e2f6649fd69ce4f1ca1674a40039b0 (diff)
util: introduce physical_memory_scale() to unify how we scale by physical memory
The various bits of code did the scaling all different, let's unify this, given that the code is not trivial.
Diffstat (limited to 'src/basic/util.h')
-rw-r--r--src/basic/util.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/basic/util.h b/src/basic/util.h
index 9e6df19ef1..db105197e8 100644
--- a/src/basic/util.h
+++ b/src/basic/util.h
@@ -184,6 +184,7 @@ int namespace_open(pid_t pid, int *pidns_fd, int *mntns_fd, int *netns_fd, int *
int namespace_enter(int pidns_fd, int mntns_fd, int netns_fd, int userns_fd, int root_fd);
uint64_t physical_memory(void);
+uint64_t physical_memory_scale(uint64_t v, uint64_t max);
int update_reboot_parameter_and_warn(const char *param);