Lines Matching refs:quota
6506 static int tg_set_cfs_bandwidth(struct task_group *tg, u64 period, u64 quota) in tg_set_cfs_bandwidth() argument
6519 if (quota < min_cfs_quota_period || period < min_cfs_quota_period) in tg_set_cfs_bandwidth()
6536 ret = __cfs_schedulable(tg, period, quota); in tg_set_cfs_bandwidth()
6540 runtime_enabled = quota != RUNTIME_INF; in tg_set_cfs_bandwidth()
6541 runtime_was_enabled = cfs_b->quota != RUNTIME_INF; in tg_set_cfs_bandwidth()
6550 cfs_b->quota = quota; in tg_set_cfs_bandwidth()
6584 u64 quota, period; in tg_set_cfs_quota() local
6588 quota = RUNTIME_INF; in tg_set_cfs_quota()
6590 quota = (u64)cfs_quota_us * NSEC_PER_USEC; in tg_set_cfs_quota()
6592 return tg_set_cfs_bandwidth(tg, period, quota); in tg_set_cfs_quota()
6599 if (tg->cfs_bandwidth.quota == RUNTIME_INF) in tg_get_cfs_quota()
6602 quota_us = tg->cfs_bandwidth.quota; in tg_get_cfs_quota()
6610 u64 quota, period; in tg_set_cfs_period() local
6613 quota = tg->cfs_bandwidth.quota; in tg_set_cfs_period()
6615 return tg_set_cfs_bandwidth(tg, period, quota); in tg_set_cfs_period()
6654 u64 period, quota; member
6664 u64 quota, period; in normalize_cfs_quota() local
6668 quota = d->quota; in normalize_cfs_quota()
6671 quota = tg_get_cfs_quota(tg); in normalize_cfs_quota()
6675 if (quota == RUNTIME_INF || quota == -1) in normalize_cfs_quota()
6678 return to_ratio(period, quota); in normalize_cfs_quota()
6685 s64 quota = 0, parent_quota = -1; in tg_cfs_schedulable_down() local
6688 quota = RUNTIME_INF; in tg_cfs_schedulable_down()
6692 quota = normalize_cfs_quota(tg, d); in tg_cfs_schedulable_down()
6701 quota = min(quota, parent_quota); in tg_cfs_schedulable_down()
6703 if (quota == RUNTIME_INF) in tg_cfs_schedulable_down()
6704 quota = parent_quota; in tg_cfs_schedulable_down()
6705 else if (parent_quota != RUNTIME_INF && quota > parent_quota) in tg_cfs_schedulable_down()
6709 cfs_b->hierarchical_quota = quota; in tg_cfs_schedulable_down()
6714 static int __cfs_schedulable(struct task_group *tg, u64 period, u64 quota) in __cfs_schedulable() argument
6720 .quota = quota, in __cfs_schedulable()
6723 if (quota != RUNTIME_INF) { in __cfs_schedulable()
6725 do_div(data.quota, NSEC_PER_USEC); in __cfs_schedulable()
6910 long period, long quota) in cpu_period_quota_print() argument
6912 if (quota < 0) in cpu_period_quota_print()
6915 seq_printf(sf, "%ld", quota); in cpu_period_quota_print()
6955 u64 quota; in cpu_max_write() local
6958 ret = cpu_period_quota_parse(buf, &period, "a); in cpu_max_write()
6960 ret = tg_set_cfs_bandwidth(tg, period, quota); in cpu_max_write()