See the related commit in pve-common.

Signed-off-by: Fiona Ebner <f.eb...@proxmox.com>
---
 PVE/QemuServer.pm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index 73e38292..5bcc75f9 100644
--- a/PVE/QemuServer.pm
+++ b/PVE/QemuServer.pm
@@ -4885,7 +4885,7 @@ sub vmconfig_hotplug_pending {
                die "skip\n" if !$hotplug_features->{memory};
                PVE::QemuServer::Memory::qemu_memory_hotplug($vmid, $conf, 
$defaults, $opt);
            } elsif ($opt eq 'cpuunits') {
-               $cgroup->change_cpu_shares(undef, 1024);
+               $cgroup->change_cpu_shares(undef);
            } elsif ($opt eq 'cpulimit') {
                $cgroup->change_cpu_quota(undef, undef); # reset, cgroup module 
can better decide values
            } else {
@@ -4980,7 +4980,7 @@ sub vmconfig_hotplug_pending {
                $value = PVE::QemuServer::Memory::qemu_memory_hotplug($vmid, 
$conf, $defaults, $opt, $value);
            } elsif ($opt eq 'cpuunits') {
                my $new_cpuunits = 
PVE::GuestHelpers::get_cpuunits($conf->{pending}->{$opt}); #clamp
-               $cgroup->change_cpu_shares($new_cpuunits, 1024);
+               $cgroup->change_cpu_shares($new_cpuunits);
            } elsif ($opt eq 'cpulimit') {
                my $cpulimit = $conf->{pending}->{$opt} == 0 ? -1 : 
int($conf->{pending}->{$opt} * 100000);
                $cgroup->change_cpu_quota($cpulimit, 100000);
-- 
2.30.2



_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to