parse-util: prefix load average macros with LOAD_AVG_

Follow-up for #20839
This commit is contained in:
Luca Boccassi
2021-09-27 20:34:41 +02:00
committed by Lennart Poettering
parent 49e9218ae3
commit 3542da2442
6 changed files with 51 additions and 51 deletions
+4 -4
View File
@@ -740,13 +740,13 @@ int parse_oom_score_adjust(const char *s, int *ret) {
int store_loadavg_fixed_point(unsigned long i, unsigned long f, loadavg_t *ret) {
assert(ret);
if (i >= (~0UL << PRECISION_BITS))
if (i >= (~0UL << LOADAVG_PRECISION_BITS))
return -ERANGE;
i = i << PRECISION_BITS;
f = DIV_ROUND_UP((f << PRECISION_BITS), 100);
i = i << LOADAVG_PRECISION_BITS;
f = DIV_ROUND_UP((f << LOADAVG_PRECISION_BITS), 100);
if (f >= FIXED_POINT_1_0)
if (f >= LOADAVG_FIXED_POINT_1_0)
return -ERANGE;
*ret = i | f;