[pve-devel] [PATCH v3 qemu-server 4/7] Rename disksize to bootdisk_size and print_drive_full to print_drive_commandline_full
Fabian Ebner
f.ebner at proxmox.com
Mon Mar 2 11:33:45 CET 2020
to avoid confusion with print_drive
Signed-off-by: Fabian Ebner <f.ebner at proxmox.com>
---
PVE/QemuServer.pm | 8 ++++----
PVE/QemuServer/Drive.pm | 2 +-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index f636150..d68fbc2 100644
--- a/PVE/QemuServer.pm
+++ b/PVE/QemuServer.pm
@@ -1406,7 +1406,7 @@ sub get_initiator_name {
return $initiator;
}
-sub print_drive_full {
+sub print_drive_commandline_full {
my ($storecfg, $vmid, $drive) = @_;
my $path;
@@ -2456,7 +2456,7 @@ sub vmstatus {
# fixme: better status?
$d->{status} = $list->{$vmid}->{pid} ? 'running' : 'stopped';
- my $size = PVE::QemuServer::Drive::disksize($storecfg, $conf);
+ my $size = PVE::QemuServer::Drive::bootdisk_size($storecfg, $conf);
if (defined($size)) {
$d->{disk} = 0; # no info available
$d->{maxdisk} = $size;
@@ -3407,7 +3407,7 @@ sub config_to_command {
$ahcicontroller->{$controller}=1;
}
- my $drive_cmd = print_drive_full($storecfg, $vmid, $drive);
+ my $drive_cmd = print_drive_commandline_full($storecfg, $vmid, $drive);
push @$devices, '-drive',$drive_cmd;
push @$devices, '-device', print_drivedevice_full($storecfg, $conf, $vmid, $drive, $bridges, $arch, $machine_type);
});
@@ -3789,7 +3789,7 @@ sub qemu_objectdel {
sub qemu_driveadd {
my ($storecfg, $vmid, $device) = @_;
- my $drive = print_drive_full($storecfg, $vmid, $device);
+ my $drive = print_drive_commandline_full($storecfg, $vmid, $device);
$drive =~ s/\\/\\\\/g;
my $ret = PVE::QemuServer::Monitor::hmp_cmd($vmid, "drive_add auto \"$drive\"");
diff --git a/PVE/QemuServer/Drive.pm b/PVE/QemuServer/Drive.pm
index ec4b6ca..1af1d36 100644
--- a/PVE/QemuServer/Drive.pm
+++ b/PVE/QemuServer/Drive.pm
@@ -547,7 +547,7 @@ sub foreach_volid {
}
}
-sub disksize {
+sub bootdisk_size {
my ($storecfg, $conf) = @_;
my $bootdisk = $conf->{bootdisk};
--
2.20.1
More information about the pve-devel
mailing list