mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 21:55:25 +00:00
vircgroup: drop unused function virCgroupSetupCpuShares
Previous commit removed all usage of this function so we can remove it. Signed-off-by: Pavel Hrdina <phrdina@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
e95489d813
commit
a924927c39
@ -1934,7 +1934,6 @@ virCgroupSetupBlkioDeviceWriteBps;
|
||||
virCgroupSetupBlkioDeviceWriteIops;
|
||||
virCgroupSetupCpuPeriodQuota;
|
||||
virCgroupSetupCpusetCpus;
|
||||
virCgroupSetupCpuShares;
|
||||
virCgroupSupportsCpuBW;
|
||||
virCgroupTerminateMachine;
|
||||
|
||||
|
@ -3899,26 +3899,6 @@ virCgroupSetupCpusetCpus(virCgroupPtr cgroup, virBitmapPtr cpumask)
|
||||
}
|
||||
|
||||
|
||||
/* Per commit 97814d8ab3, the Linux kernel can consider a 'shares'
|
||||
* value of '0' and '1' as 2, and any value larger than a maximum
|
||||
* is reduced to maximum.
|
||||
*
|
||||
* The 'realValue' pointer holds the actual 'shares' value set by
|
||||
* the kernel if the function returned success. */
|
||||
int
|
||||
virCgroupSetupCpuShares(virCgroupPtr cgroup, unsigned long long shares,
|
||||
unsigned long long *realValue)
|
||||
{
|
||||
if (virCgroupSetCpuShares(cgroup, shares) < 0)
|
||||
return -1;
|
||||
|
||||
if (virCgroupGetCpuShares(cgroup, realValue) < 0)
|
||||
return -1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
virCgroupSetupCpuPeriodQuota(virCgroupPtr cgroup,
|
||||
unsigned long long period,
|
||||
|
@ -227,8 +227,6 @@ virCgroupGetDomainTotalCpuStats(virCgroupPtr group,
|
||||
|
||||
int virCgroupSetCpuShares(virCgroupPtr group, unsigned long long shares);
|
||||
int virCgroupGetCpuShares(virCgroupPtr group, unsigned long long *shares);
|
||||
int virCgroupSetupCpuShares(virCgroupPtr cgroup, unsigned long long shares,
|
||||
unsigned long long *realValue);
|
||||
|
||||
#define VIR_CGROUP_CPU_SHARES_MIN 2LL
|
||||
#define VIR_CGROUP_CPU_SHARES_MAX 262144LL
|
||||
|
Loading…
Reference in New Issue
Block a user