dm: virtio: fix compile issue on ubuntu

As VIRTIO_CONFIG_S_NEEDS_RESET is not defined in standard virtio header
file on ubuntu, there will be compile issue. so add
VIRTIO_CONFIG_S_NEEDS_RESET to fix it.

Tracked-On: #2145
Signed-off-by: Conghui Chen <conghui.chen@intel.com>
Reviewed-by: Jian Jun Chen <jian.jun.chen@intel.com>
Acked-by: Yin Fengwei <fengwei.yin@intel.com>
This commit is contained in:
Conghui Chen 2018-12-22 08:25:47 +08:00 committed by wenlingz
parent 9fe282f080
commit 44bee5168e
1 changed files with 8 additions and 0 deletions

View File

@ -229,6 +229,14 @@ enum {
#define VIRTIO_DEV_HDCP 0x8607 #define VIRTIO_DEV_HDCP 0x8607
#define VIRTIO_DEV_COREU 0x8608 #define VIRTIO_DEV_COREU 0x8608
/*
* VIRTIO_CONFIG_S_NEEDS_RESET is not defined
* in some environments's virtio_config.h
*/
#ifndef VIRTIO_CONFIG_S_NEEDS_RESET
#define VIRTIO_CONFIG_S_NEEDS_RESET 0x40
#endif
/* /*
* Bits in VIRTIO_PCI_ISR. These apply only if not using MSI-X. * Bits in VIRTIO_PCI_ISR. These apply only if not using MSI-X.
* *