From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id BA4DC9A731 for ; Fri, 17 Nov 2023 13:24:50 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 8D65932AB8 for ; Fri, 17 Nov 2023 13:24:20 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS for ; Fri, 17 Nov 2023 13:24:19 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id C695143DEA for ; Fri, 17 Nov 2023 13:24:18 +0100 (CET) Message-ID: Date: Fri, 17 Nov 2023 13:24:17 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: pve-devel@lists.proxmox.com References: <20231117115311.111320-1-h.duerr@proxmox.com> <20231117115311.111320-5-h.duerr@proxmox.com> From: =?UTF-8?Q?Hannes_D=C3=BCrr?= In-Reply-To: <20231117115311.111320-5-h.duerr@proxmox.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.001 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record T_SCC_BODY_TEXT_LINE -0.01 - URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [proxmox.com, qemuserver.pm, qemu.pm, drive.pm] Subject: Re: [pve-devel] [PATCH v4 qemu-server 4/4] fix #4957: add vendor and product information passthrough for SCSI-Disks X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Nov 2023 12:24:50 -0000 New Version can be found here: https://lists.proxmox.com/pipermail/pve-devel/2023-November/060429.html On 11/17/23 12:53, Hannes Duerr wrote: > adds vendor and product information for SCSI devices to the json schema and > checks in the VM create/update API call if it is possible to add these to QEMU as a device option > > Signed-off-by: Hannes Duerr > --- > PVE/API2/Qemu.pm | 39 +++++++++++++++++++++++++++++++++++++++ > PVE/QemuServer.pm | 13 ++++++++++++- > PVE/QemuServer/Drive.pm | 24 ++++++++++++++++++++++++ > 3 files changed, 75 insertions(+), 1 deletion(-) > > __PACKAGE__->register_method({ > name => 'vmlist', > path => '', > @@ -1011,6 +1038,13 @@ __PACKAGE__->register_method({ > my $conf = $param; > my $arch = PVE::QemuServer::get_vm_arch($conf); > > + for my $opt (sort keys $param->%*) { > + if ($opt =~ m/^scsi(\d)+$/) { > + assert_scsi_feature_compatibility( > + $opt, $conf, $storecfg, $param->{$opt}); > + } > + } > + > $conf->{meta} = PVE::QemuServer::new_meta_info_string(); > > my $vollist = []; > @@ -1826,6 +1860,11 @@ my $update_vm_api = sub { > PVE::QemuServer::vmconfig_register_unused_drive($storecfg, $vmid, $conf, PVE::QemuServer::parse_drive($opt, $conf->{pending}->{$opt})) > if defined($conf->{pending}->{$opt}); > > + if ($opt =~ m/^scsi(\d)+$/) { > + PVE::QemuServer::assert_scsi_feature_compatibility( > + $opt, $conf, $storecfg, $param->{$opt}); ^ copy paste error > + } > + > my (undef, $created_opts) = $create_disks->( > $rpcenv, > $authuser,