[pve-devel] [PATCH v5 qemu-server 4/4] fix #4957: add vendor and product information passthrough for SCSI-Disks

Fiona Ebner f.ebner at proxmox.com
Mon Nov 20 17:33:25 CET 2023


Am 17.11.23 um 13:17 schrieb Hannes Duerr:
> diff --git a/PVE/QemuServer/Drive.pm b/PVE/QemuServer/Drive.pm
> index de62d43..4e1646d 100644
> --- a/PVE/QemuServer/Drive.pm
> +++ b/PVE/QemuServer/Drive.pm
> @@ -161,6 +161,26 @@ my %iothread_fmt = ( iothread => {
>  	optional => 1,
>  });
>  
> +my %product_fmt = (
> +    product => {
> +	type => 'string',
> +	pattern => '[A-Za-z0-9\-_]{,40}',
> +	format_description => 'product',
> +	description => "The drive's product name, up to 40 bytes long.",
> +	optional => 1,
> +    },
> +);
> +
> +my %vendor_fmt = (
> +    vendor => {
> +	type => 'string',
> +	pattern => '[A-Za-z0-9\-_]{,40}',

I wonder if we should allow spaces? QEMU itself seems to support it and
I can imagine some vendor or product to include some. But maybe it's not
a good practice? Can still be extended later of course.





More information about the pve-devel mailing list