ui: pci passthrough: editor for pci-id overrides

Signed-off-by: Nicholas Sherlock <n.sherlock@gmail.com>
This commit is contained in:
Nicholas Sherlock
2022-01-18 21:38:40 +00:00
committed by Thomas Lamprecht
parent b241deb731
commit 9a9be673d1
2 changed files with 38 additions and 0 deletions

View File

@ -13,6 +13,8 @@ Ext.apply(Ext.form.field.VTypes, {
IP64AddressWithSuffixList: v => PVE.Utils.verify_ip64_address_list(v, true),
IP64AddressListText: gettext('Example') + ': 192.168.1.1,192.168.1.2',
IP64AddressListMask: /[A-Fa-f0-9,:.; ]/,
PciIdText: gettext('Example') + ': 0x8086',
PciId: v => /^0x[0-9a-fA-F]{4}$/.test(v),
});
Ext.define('PVE.form.field.Display', {

View File

@ -190,6 +190,24 @@ Ext.define('PVE.qemu.PCIInputPanel', {
fieldLabel: 'ROM-File',
name: 'romfile',
},
{
xtype: 'textfield',
name: 'vendor-id',
fieldLabel: gettext('Set vendor ID'),
vtype: 'PciId',
allowBlank: true,
emptyText: Proxmox.Utils.defaultText,
submitEmpty: false,
},
{
xtype: 'textfield',
name: 'device-id',
fieldLabel: gettext('Set device ID'),
vtype: 'PciId',
allowBlank: true,
emptyText: Proxmox.Utils.defaultText,
submitEmpty: false,
},
];
me.advancedColumn2 = [
@ -198,6 +216,24 @@ Ext.define('PVE.qemu.PCIInputPanel', {
fieldLabel: 'PCI-Express',
name: 'pcie',
},
{
xtype: 'textfield',
name: 'sub-vendor-id',
fieldLabel: gettext('Set sub-vendor ID'),
vtype: 'PciId',
allowBlank: true,
emptyText: Proxmox.Utils.defaultText,
submitEmpty: false,
},
{
xtype: 'textfield',
name: 'sub-device-id',
fieldLabel: gettext('Set sub-device ID'),
vtype: 'PciId',
allowBlank: true,
emptyText: Proxmox.Utils.defaultText,
submitEmpty: false,
},
];
me.callParent();