- CGroupContext *c = data;
- unsigned long lu;
- int r;
-
- assert(filename);
- assert(lvalue);
- assert(rvalue);
-
- if (isempty(rvalue)) {
- c->blockio_weight = 1000;
- return 0;
- }
-
- r = safe_atolu(rvalue, &lu);
- if (r < 0 || lu < 10 || lu > 1000) {
- log_syntax(unit, LOG_ERR, filename, line, EINVAL,
- "Block IO weight '%s' invalid. Ignoring.", rvalue);
- return 0;
- }
-
- c->blockio_weight = lu;
- if (!c->startup_blockio_weight_set)
- c->startup_blockio_weight = lu;
-
- return 0;
-}
-
-int config_parse_startup_blockio_weight(
- const char *unit,
- const char *filename,
- unsigned line,
- const char *section,
- unsigned section_line,
- const char *lvalue,
- int ltype,
- const char *rvalue,
- void *data,
- void *userdata) {
-
- CGroupContext *c = data;
- unsigned long lu;