chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
util: introduce physical_memory_scale() to unify how we scale by physical memory
[elogind.git]
/
src
/
login
/
logind.c
diff --git
a/src/login/logind.c
b/src/login/logind.c
index 4006bf1385616fde7b4995fb6f2a32c6e895eed0..45fe8a9221dc70eeefb05c9b0cde9cb85bcb41c4 100644
(file)
--- a/
src/login/logind.c
+++ b/
src/login/logind.c
@@
-78,7
+78,7
@@
static void manager_reset_config(Manager *m) {
m->idle_action_usec = 30 * USEC_PER_MINUTE;
m->idle_action = HANDLE_IGNORE;
m->idle_action_usec = 30 * USEC_PER_MINUTE;
m->idle_action = HANDLE_IGNORE;
- m->runtime_dir_size =
PAGE_ALIGN((size_t) (physical_memory() / 10)
); /* 10% */
+ m->runtime_dir_size =
physical_memory_scale(10U, 100U
); /* 10% */
m->user_tasks_max = 12288;
m->sessions_max = 8192;
m->inhibitors_max = 8192;
m->user_tasks_max = 12288;
m->sessions_max = 8192;
m->inhibitors_max = 8192;