mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2026-06-06 17:21:22 +00:00
dm: Add Oracle subsystem vendor ID
After Windows 10, version 1607, the cross-signed drivers are forbiden to load when secure boot is enabled. Details please refer to https://docs.microsoft.com/en-us/windows-hardware/drivers/install/kernel-mode-code-signing-policy--windows-vista-and-later- That means the kvm-guest-drivers-windows can't work when secure boot enabled. So we found another windows virtio FE drivers from Oracle to resolve this issue but have to change another subsystem vendor ID for the virtio BE services. This patch introduces a new DM CMD line "--windows" to launch WaaG with Oracle virtio devices including virtio-blk, virtio-net, virtio-input instead Redhat. It can make virtio-blk, virtio-net and virtio-input devices work when WaaG enabling secure boot. Tracked-On: #3583 Signed-off-by: Yuan Liu <yuan1.liu@intel.com> Reviewed-by: Eddie Dong <eddie.dong@intel.com> Acked-by: Yin Fengwei <fengwei.yin@intel.com>
This commit is contained in:
committed by
ACRN System Integration
parent
bb1a8eea40
commit
a4d562daa0
@@ -544,7 +544,10 @@ virtio_blk_init(struct vmctx *ctx, struct pci_vdev *dev, char *opts)
|
||||
pci_set_cfgdata16(dev, PCIR_VENDOR, VIRTIO_VENDOR);
|
||||
pci_set_cfgdata8(dev, PCIR_CLASS, PCIC_STORAGE);
|
||||
pci_set_cfgdata16(dev, PCIR_SUBDEV_0, VIRTIO_TYPE_BLOCK);
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, VIRTIO_VENDOR);
|
||||
if (is_winvm == true)
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, ORACLE_VENDOR_ID);
|
||||
else
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, VIRTIO_VENDOR);
|
||||
|
||||
if (virtio_interrupt_init(&blk->base, virtio_uses_msix())) {
|
||||
/* call close only for valid bctxt */
|
||||
|
||||
@@ -700,7 +700,10 @@ virtio_input_init(struct vmctx *ctx, struct pci_vdev *dev, char *opts)
|
||||
pci_set_cfgdata8(dev, PCIR_CLASS, PCIC_INPUTDEV);
|
||||
pci_set_cfgdata8(dev, PCIR_SUBCLASS, PCIS_INPUTDEV_OTHER);
|
||||
pci_set_cfgdata16(dev, PCIR_SUBDEV_0, 0x1100);
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, VIRTIO_VENDOR);
|
||||
if (is_winvm == true)
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, ORACLE_VENDOR_ID);
|
||||
else
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, VIRTIO_VENDOR);
|
||||
pci_set_cfgdata16(dev, PCIR_REVID, 1);
|
||||
|
||||
if (virtio_interrupt_init(&vi->base, virtio_uses_msix())) {
|
||||
|
||||
@@ -866,7 +866,10 @@ virtio_net_init(struct vmctx *ctx, struct pci_vdev *dev, char *opts)
|
||||
pci_set_cfgdata16(dev, PCIR_VENDOR, VIRTIO_VENDOR);
|
||||
pci_set_cfgdata8(dev, PCIR_CLASS, PCIC_NETWORK);
|
||||
pci_set_cfgdata16(dev, PCIR_SUBDEV_0, VIRTIO_TYPE_NET);
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, VIRTIO_VENDOR);
|
||||
if (is_winvm == true)
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, ORACLE_VENDOR_ID);
|
||||
else
|
||||
pci_set_cfgdata16(dev, PCIR_SUBVEND_0, VIRTIO_VENDOR);
|
||||
|
||||
/* Link is up if we managed to open tap device */
|
||||
net->config.status = (opts == NULL || net->tapfd >= 0);
|
||||
|
||||
Reference in New Issue
Block a user