parse-util: prefix load average macros with LOAD_AVG_
Follow-up for #20839
This commit is contained in:
committed by
Lennart Poettering
parent
49e9218ae3
commit
3542da2442
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user