[PATCH wiki] Updated the new version GVTg_Setup_Guide (markdown).

Terrence Xu terrence.xu at intel.com
Tue Feb 21 08:20:10 UTC 2017


Signed-off-by: Terrence Xu <terrence.xu at intel.com>
---
 GVTg_Setup_Guide.md | 423 ++++++++++++++++++++++++++++++++--------------------
 1 file changed, 263 insertions(+), 160 deletions(-)

diff --git a/GVTg_Setup_Guide.md b/GVTg_Setup_Guide.md
index 6996cba..f74fe6b 100644
--- a/GVTg_Setup_Guide.md
+++ b/GVTg_Setup_Guide.md
@@ -1,50 +1,94 @@
-# Introduction #
-
-Intel® Graphics Virtualization Technology GVT-g is a full GPU virtualization solution with mediated pass-through support starting from 4th Generation Intel Core processors with Intel Graphics processors (Broadwell).  
-
-A virtual GPU instance is maintained for each virtual machine, with performance-critical resources directly assigned. Running a native graphics driver inside a VM(without hypervisor intervention in performance critical paths) optimizes resources among the performance, feature, and sharing capabilities.  
-
-KVM is currently upstreamed on Intel Processor Graphics(a.k.a. KVMGT) based on VFIO framework.
-
-# Environment Setup #
-
-Below is the upstream work focus is KVMGT with VFIO. Below the description of environment setup of KVMGT with VFIO.
+Contents
+=================
+
+   * [1 Introduction](#1-introduction)
+   * [2 System Reruirements](#2-system-reruirements)
+      * [2.1 Operating System Requirements](#21-operating-system-requirements)
+      * [2.2 Hardware Requirements](#22-hardware-requirements)
+      * [2.3 Library Dependence](#23-library-dependence)
+   * [3 Host Environment Setup](#3-host-environment-setup)
+      * [3.1 Source Repositories](#31-source-repositories)
+      * [3.2 Build Kernel](#32-build-kernel)
+         * [3.2.1 Build the initrd (initial ramdisk)](#321-build-the-initrd-initial-ramdisk)
+         * [3.2.2 Build Kernel Source](#322-build-kernel-source)
+      * [3.3 Build Qemu](#33-build-qemu)
+      * [3.4 Grub Update](#34-grub-update)
+   * [4 Guest Setup](#4-guest-setup)
+      * [4.1 Linux Guest Setup](#41-linux-guest-setup)
+         * [4.1.1 Linux Kernel Support](#411-linux-kernel-support)
+         * [4.1.2 Linux Intel GFX Card Support](#412-linux-intel-gfx-card-support)
+         * [4.1.3 Linux Remote Protocol Support](#413-linux-remote-protocol-support)
+      * [4.2 Windows Guest Setup](#42-windows-guest-setup)
+         * [4.2.1 Windows Version Support](#421-windows-version-support)
+         * [4.2.2 Windows GFX Driver Support](#422-windows-gfx-driver-support)
+         * [4.2.3 Windows Remote Protocol Support](#423-windows-remote-protocol-support)
+   * [5 Basic usage](#5-basic-usage)
+      * [5.1 Check mdev Module](#51-check-mdev-module)
+      * [5.2 Generate the uuid for create VGPU](#52-generate-the-uuid-for-create-vgpu)
+      * [5.3 Create VGPU](#53-create-vgpu)
+      * [5.4 Remove VGPU](#54-remove-vgpu)
+      * [5.5 Network Bridge](#55-network-bridge)
+      * [5.6 Create VM](#56-create-vm)
+   * [6 Features Supported](#6-features-supported)
+      * [6.1 Highlights Features](#61-highlights-features)
+      * [6.2 Validated Benchmarks](#62-validated-benchmarks)
+
+
+
+# 1 Introduction #
+
+Intel GVT-g for KVM (a.k.a. KVMGT) is a full GPU virtualization solution with mediated pass-through (VFIO mediated device framework based), starting from 5th generation Intel Core(TM) processors with Intel Graphics processors.
+A virtual GPU instance is maintained for each VM, with part of performance critical resources directly assigned. The capability of running native graphics driver inside a VM, without hypervisor intervention in performance critical paths, achieves a good balance among performance, feature, and sharing capability.
+
+# 2 System Reruirements #
+
+## 2.1 Operating System Requirements  ##
+ Ubuntu 16.04.1 has been fully validated as host, other Linux operating system like RHEL / Fedora are also OK.
+ 
+## 2.2 Hardware Requirements  ##
+5th or 6th Generation Intel® Core Processor Graphics is required.
 
-## Build KVMGT from source ##
+## 2.3 Library Dependence  ##
+Use Ubuntu as example, there are some software package needed by host environment setup, as below:
+>   apt-get install git libfdt-dev libpixman-1-dev libssl-dev vim socat libsdl1.2-dev libspice-server-dev autoconf libtool xtightvncviewer tightvncserver x11vnc libsdl1.2-dev uuid-runtime uuid uml-utilities bridge-utils 
 
 
->  gvt kernel tip: https://github.com/01org/gvt-linux.git "gvt-staging" branch 
+# 3 Host Environment Setup #
 
->  QEMU: git://git.qemu.org/qemu.git 
+## 3.1 Source Repositories ##
 
-Modify /etc/initramfs-tools/modules, like below:
+    GVT-g kernel tip: https://github.com/01org/gvt-linux.git (branch: "gvt-stable-4.10") 
+    QEMU: git://git.qemu.org/qemu.git (tag: "v2.8.0")
 
+## 3.2 Build Kernel ##
+### 3.2.1 Build the initrd (initial ramdisk)  ###
+Use Ubuntu as example, modify /etc/initramfs-tools/modules, like below:
 > kvmgt  
 > vfio-iommu-type1  
 > vfio-mdev
+For Fedora or RHEL you should make the similar changes in "dracut".
 
-Build Kernel:
+### 3.2.2 Build Kernel Source ###
 
 > git clone https://github.com/01org/gvt-linux.git
 
 > cd gvt-linux  
 
-Make sure to enable **CONFIG_DRM_I915_GVT** and **CONFIG_DRM_I915_GVT_KVMGT**, which depends on **CONFIG_VFIO_MDEV** and **CONFIG_VFIO_MDEV_DEVICE**.
-
-> make -j8 && make modules_install && make install
+>git checkout gvt-stable-4.10
 
+> echo ""|make oldconfig
+Then make sure to enable **CONFIG_DRM_I915_GVT** and **CONFIG_DRM_I915_GVT_KVMGT** in ".config", which depends on **CONFIG_VFIO_MDEV** and **CONFIG_VFIO_MDEV_DEVICE**. 
 
-Build Qemu: In order to config the network for guest, below packages are needed, as described in "README.kvmgt" in QEMU repo:
-> apt-get install uml-utilities bridge-utils
+> make -j8 && make modules_install && make install
 
-After rebooting machine, there should be "virbr0" seen from "ifconfig".
+## 3.3 Build Qemu ##
 Then build QEMU as follow:
 
 > git clone git://git.qemu.org/qemu.git 
 
 > cd qemu  
 
-> git submodule update --init dtc  
+> git checkout v2.8.0
 
 > git submodule update --init roms/seabios  
 
@@ -55,6 +99,7 @@ Then build QEMU as follow:
 >             --enable-debug          \  
 >             --enable-sdl            \  
 >             --enable-vhost-net      \  
+>             --enable-spice      \  
 >             --disable-debug-tcg     \  
 >             --target-list=x86_64-softmmu  
 
@@ -62,7 +107,6 @@ Then build QEMU as follow:
 
 > cd roms/seabios  
 
-> (Modifiy the "src/Kconfig" line 329, change the USE_SMM default value from "y" to "n")  
 > make -j8  
 
 > cd -  
@@ -71,145 +115,204 @@ Then build QEMU as follow:
 
 > cp roms/seabios/out/bios.bin /usr/bin/bios.bin
 
-## Grub update ##
-
-Make sure the “i915.enable_gvt=1” exist in host grub.cfg, the example as below:
->menuentry 'upstream vfio' --class kvmgt --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-106518cd-fb74-4048-81de-3ecee7ad74d4' {  
->       recordfail  
->       load_video  
->           gfxmode $linux_gfx_mode  
->           insmod gzio  
->           insmod part_msdos  
->           insmod ext2  
->           set root='hd0,msdos1'  
->           if [ x$feature_platform_search_hint = xy ]; then
->              search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  106518cd-fb74-4048-81de-3ecee7ad74d4  
->           else  
->              search --no-floppy --fs-uuid --set=root 106518cd-fb74-4048-81de-3ecee7ad74d4  
->           fi  
->            linux   /boot/vgt/host-vgt root=UUID=106518cd-fb74-4048-81de-3ecee7ad74d4 ro ignore_loglevel intel_iommu=igfx_off i915.hvm_boot_foreground=1 log_buf_len=128M console=ttyS0,115200,8n1 drm.debug=0 i915.enable_gvt=1  
->            initrd  /boot/vgt/initrd-vgt.img  
->}  
-
-# Basic Usage #
-## Preparation ##
-
-### 1. Check environment  ###
-Make sure the "mdev_supported_types" node existed, like below (The "V#ID" represent the corresponding GPU generation, "V4" means it is "Broadwell" platform):
-> root at bdwhupstream-host:~# ll /sys/bus/pci/devices/0000\:00\:02.0/mdev_supported_types/  
-> total 0  
-> drwxr-xr-x  5 root root 0 Apr 16 21:24 ./  
-> drwxr-xr-x 12 root root 0 Apr 16 20:04 ../  
-> drwxr-xr-x  3 root root 0 Apr 16 21:24 i915-GVTg_V4_1/  # This node max support 1 VM  
-> drwxr-xr-x  3 root root 0 Apr 16 21:24 i915-GVTg_V4_2/  # This node max support 2 VMs  
-> drwxr-xr-x  3 root root 0 Apr 16 21:24 i915-GVTg_V4_4/   # This node max support 4 VMs  
-
-### 2. Generate the uuid for create VGPU  ###
-For example, if we need to create 3 VM, we must create 3 uuid for 3 VGPU, like below:
-> root at bdwhupstream-host:~# uuidgen  
-> 894f3983-1a36-42b3-b52c-1024aca216be  
-> root at bdwhupstream-host:~# uuidgen  
-> 2922d49f-2485-4f12-87c6-ed1cd8c798b0  
-> root at bdwhupstream-host:~# uuidgen  
-> 127bd07a-d59d-48e2-8c5c-e1b4b8e1026c  
-
-### 3. Create VGPUs 
-Use the uuid you generated to create VGPU, notes: if you want to boot up multi guests, you can use echo "uuid" > "/sys/bus/pci/devices/0000:00:02.0/mdev_supported_types/i915-GVTg_V4_4/create", like below:  ###
-
-> root at bdwhupstream-host:~# cat create-vgpu.sh:  
-
-> echo "894f3983-1a36-42b3-b52c-1024aca216be" "/sys/bus/pci/devices/0000:00:02.0/  mdev_supported_types/i915-GVTg_V4_4/create"  
-> echo "2922d49f-2485-4f12-87c6-ed1cd8c798b0" "/sys/bus/pci/devices/0000:00:02.0/  mdev_supported_types/i915-GVTg_V4_4/create"  
-> echo "127bd07a-d59d-48e2-8c5c-e1b4b8e1026c" "/sys/bus/pci/devices/0000:00:02.0/  mdev_supported_types/i915-GVTg_V4_4/create"  
-
-## Create VM with vfio ##
-
-The create VM script example as below:
-create-vfio
->  #! /bin/bash -x  
-> /usr/bin/qemu-system-x86_64 \  
-> -m 2048 -smp 2 -M pc \  
-> -name kvmgt1 \  
-> -hda /home/img/ubuntu-1.qcow2  \  
-> -bios /usr/bin/bios.bin -enable-kvm \  
-> -net nic,macaddr=00:A1:00:00:00:1A -net tap,script=/etc/qemu-ifup \  
-> -vga none -device isa-vga \  
-> -k en-us \  
-> -serial stdio \  
-> -vnc :1 \  
-> -machine kernel_irqchip=on \  
-> -global PIIX4_PM.disable_s3=1 -global PIIX4_PM.disable_s4=1 \  
-> -cpu host -usb -usbdevice tablet \  
-> -device vfio-pci,sysfsdev=/sys/bus/pci/devices/0000:00:02.0/894f3983-1a36-42b3-b52c-1024aca216be   
-
-(the uuid is the same with create-vgpu.sh)  
-notes:if you want to boot up multi guests, you should create the similar create vm script like "create-vfio2" / "create-vfio3" with different name / vnc port / UUID, etc.  
- 
+## 3.4 Grub Update ##
+
+Make sure the “i915.enable_gvt=1” exist in host grub.cfg, use  Ubuntu as example, as below: 
+
+    menuentry 'GVT-g Upstream' --class kvmgt --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-106518cd-fb74-4048-81de-3ecee7ad74d4' {  
+        recordfail  
+        load_video  
+        gfxmode $linux_gfx_mode  
+        insmod gzio  
+        insmod part_msdos  
+        insmod ext2  
+        set root='hd0,msdos1'  
+        if [ x$feature_platform_search_hint = xy ]; then
+            search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1  106518cd-fb74-4048-81de-3ecee7ad74d4  
+        else  
+            search --no-floppy --fs-uuid --set=root 106518cd-fb74-4048-81de-3ecee7ad74d4  
+        fi  
+            linux   /boot/vgt/host-gvt root=UUID=106518cd-fb74-4048-81de-3ecee7ad74d4 ro ignore_loglevel log_buf_len=128M console=ttyS0,115200,8n1 i915.enable_gvt=1
+            initrd  /boot/vgt/initrd-gvt.img  
+    }  
+    
+# 4 Guest Setup #
+
+## 4.1 Linux Guest Setup ##
+
+### 4.1.1 Linux Kernel Support ###
+You can prepare any version Ubuntu guest OS image manually, and change the guest kernel to 4.8 or 4.9 (you can download the stable version from https://www.kernel.org/).
+Sugguest to use Ubuntu16.10 or Fedora25 as guest OS since they default with the 4.8 kernel.
+
+### 4.1.2 Linux Intel GFX Card Support ###
+We needs the special X11 configuration change for linux guest to use the Intel GFX card as display card (use the secondary GPU, VM default use the emulated “QXL” or "Cirrus" as default gfx card, which is not support OpenCL / OpenGL hardware acceleration, so we must make this change), use Ubuntu as example, as below (We saved it at /etc/X11/xorg.conf):
+    
+    Section "Device"
+        Identifier  "intel"
+        Driver      "intel"
+        BusID       "PCI:0:4:0"  # Sample: "PCI:0:2:0"
+    EndSection
+
+    Section "Screen"
+        Identifier "intel"
+        Device "intel"
+    EndSection
+
+BTW: The PCI ID was chose by the “lspci”
+> root at gvtg-host:~# lspci
+00:00.0 Host bridge: Intel Corporation 440FX - 82441FX PMC [Natoma] (rev 02)
+00:01.0 ISA bridge: Intel Corporation 82371SB PIIX3 ISA [Natoma/Triton II]
+00:01.1 IDE interface: Intel Corporation 82371SB PIIX3 IDE [Natoma/Triton II]
+00:01.2 USB controller: Intel Corporation 82371SB PIIX3 USB [Natoma/Triton II] (rev 01)
+00:01.3 Bridge: Intel Corporation 82371AB/EB/MB PIIX4 ACPI (rev 03)
+00:02.0 VGA compatible controller: Cirrus Logic GD 5446
+00:03.0 Ethernet controller: Intel Corporation 82540EM Gigabit Ethernet Controller (rev 03)
+00:04.0 VGA compatible controller: Intel Corporation Broadwell-U Integrated Graphics (rev 0a)
+
+NOTICE: after you changed the display card to Intel GFX card, Qemu will comes to black screen, you only can see guest desktop by remote protocal.
+
+### 4.1.3 Linux Remote Protocol Support ###
+We suggest to use the X11VNC as the remote protocol to validation.
+
+Use Ubuntu as example, to support X11VNC, you must install the xhost in guest first, the xhost program is used to add and delete host names or user names to the list allowed to make connections to the X server, you must make some configuration for lightdm, the example as below:
+
+    root at gvtg-host:~# cat /etc/profile.d/lightdm_display.sh
+    #!/bin/bash  
+        export DISPLAY=:0  
+  
+        if [ ! -z "$DISPLAY" ]; then  
+            xhost +local:  
+        fi    
 
-# VFIO validation #
-Since now the upstream code not support direct display, we must use the remote protocol for validation. And you must install the remote protocol in VM.
-## Linux VM validation ##
-For Linux VM, we use the X11 vnc as the remote protocol to validation.
-
-### VNC ###
-We cannot create terminal on Ubuntu in vnc / x11vnc by default. To allow create terminal by vnc, we must install the package in Ubuntu guest as below:
-> apt-get install vncviewer tightvncserver x11vnc gnome-panel gnome-settings-daemon metacity nautilus gnome-terminal
-
-And we should setup the vncserver configuration file /root/.vnc/xstartup as below:
-> cat /root/.vnc/xstartup  
->  #!/bin/sh  
->     
-> export XKL_XMODMAP_DISABLE=1  
-> unset SESSION_MANAGER  
-> unset DBUS_SESSION_BUS_ADDRESS  
->   
-> [ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup  
-> [ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources  
-> xsetroot -solid grey  
-> vncconfig -iconic &  
->   
-> gnome-panel &  
-> gnome-settings-daemon &  
-> metacity &  
-> nautilus &  
-> gnome-terminal &  
->   
-> gsettings set org.gnome.desktop.wm.keybindings panel-main-menu "['<Alt>F1']"  
-> gsettings set org.gnome.desktop.wm.keybindings switch-applications "['<Alt>Tab']"  
-> gsettings set org.gnome.desktop.wm.keybindings show-desktop "['<Alt>d']"  
-> gsettings set org.gnome.desktop.wm.keybindings maximize "['<Alt>Up']"  
-> gsettings set org.gnome.desktop.wm.keybindings unmaximize "['<Alt>Down']"  
-
-### Conect guest with x11vnc (with guest X support)  ###
-To allow x11vnc, you must install the xhost in guest first, the xhost program is used to add and delete host names or user names to the list allowed to make connections to the X server. To start xhost when startup lightdm, we should setup /etc/profile.d/lightdm_display.sh with the below configuration:
-
->  #!/bin/bash  
-> export DISPLAY=:0  
->   
-> if [ ! -z "$DISPLAY" ]; then  
->     xhost +local:  
-> fi    
-
-Then you must add the execute permissions for lightdm_display.sh
-> chmod +x /etc/profile.d/lightdm_display.sh  
-
-You need need to add it to /etc/lightdm/lightdm.conf, and setup "unity-greeter" as "greeter-session" to avoid the "The system is running in low-graphics mode" issue, the /etc/lightdm/lightdm.conf should be setup as below:
-> [SeatDefaults]  
-> greeter-session=unity-greeter  
-> user-session=ubuntu  
->   
-> greeter-setup-script=/etc/profile.d/lightdm_display.sh  
-> session-setup-script=/etc/profile.d/lightdm_display.sh  
-
-Then you just run the x11vnc service in guest:
+    root at gvtg-host:~# chmod +x /etc/profile.d/lightdm_display.sh  
 
+    root at gvtg-host:~# cat /etc/lightdm/lightdm.conf 
+        [SeatDefaults]  
+        greeter-session=unity-greeter  
+        user-session=ubuntu  
+        greeter-setup-script=/etc/profile.d/lightdm_display.sh  
+        session-setup-script=/etc/profile.d/lightdm_display.sh  
+
+After you completed the lightdm configuration, you can run the X11VNC service in guest as below:
+> x11vnc -storepasswd
 > x11vnc -rfbauth ~/.vnc/passwd  -display :0 -forever -bg -repeat -nowf -o ~/.vnc/x11vnc.log -rfbport 5900  
 
-then connect from remote by:
+Then connect guest by host with guest X support by:
 
-> vncviewer $guestip
+> vncviewer <guestIP>
   
-Then you can start the Linux VM validation work by x11vnc
-
-## Windows VM validation ##
-For Windows VM, we use the HP RGS or VNC and anyother remote protocol for validation.
+NOTICE: after you changed the display card to Intel GFX card, Qemu will comes to black screen, you only can see guest desktop by remote protocol.
+
+## 4.2 Windows Guest Setup ##
+### 4.2.1 Windows Version Support
+Win7-32 / Win7-64 / Win8.1-64 /Win10-RS1-64 are validated.
+
+### 4.2.2 Windows GFX Driver Support ###
+After you boot up Windows guest, you can see 2 GFX card in "Device manager" (One is the virtual GFX card "QXL" or "Cirrus", the other is Intel GFX card), then you must install the Intel GFX Windows for the Intel GFX card to support OpenCL / OpenGL / DirectX9 / DirectX10/ DirectX11 / DirectX12 hardware acceleration .
+You can get the Windows driver from Intel website: https://downloadcenter.intel.com/product/80939/Graphics-Drivers
+	Skylake:  >= 15.45.14.4910 
+	Broadwell: The driver has been published, will coming soon.
+
+NOTICE: after you installed Windows GFX driver, you can see guest desktop by both QEMU and remote protocal.
+
+### 4.2.3 Windows Remote Protocol Support ###
+All Windows Remote protocol are supported, such as TightVNC, HP RGS, RDP.
+"Tightvnc" is validated, so you can install the "Tightvnc" in Windows guest, and  you can connect guest by host with guest X support by:
+
+> vncviewer <guestIP>
+
+# 5 Basic usage #
+## 5.1 Check mdev Module  ##
+After you boot up you host to GVT-g menuentry, you make sure the "mdev_supported_types" node with differenct vgpu type existed(The "V#ID" represent the corresponding platform, "V4" means it is "Broadwell" platform, "V5" means it is "Skylake" platform), the example as below
+> root at gvtg-host:~# ll /sys/bus/pci/devices/0000:00:02.0/mdev_supported_types/  
+ total 0  
+ drwxr-xr-x  5 root root 0 Apr 16 21:24 ./  
+ drwxr-xr-x 12 root root 0 Apr 16 20:04 ../  
+ drwxr-xr-x  3 root root 0 Apr 16 21:24 i915-GVTg_V4_1/  # This node max support 1 VM  
+ drwxr-xr-x  3 root root 0 Apr 16 21:24 i915-GVTg_V4_2/  # This node max support 2 VMs  
+ drwxr-xr-x  3 root root 0 Apr 16 21:24 i915-GVTg_V4_4/   # This node max support 4 VMs  
+ 
+And you can check the detail description for each vgpu type,
+
+> root at gvtg-host:/sys/bus/pci/devices/0000:00:02.0/mdev_supported_types/i915-GVTg_V4_1# cat description
+ low_gm_size: 256MB
+ high_gm_size: 2048MB
+ fence: 4
+
+## 5.2 Generate the uuid for create VGPU  ##
+Use Ubuntu as example, you can use the third-party tool to generate uuid like "uuid", "uuidgen", if we need to create 3 VM, we must create 3 uuid for 3 VGPU, like below:
+> root at gvtg-host:~# uuid -n 3
+ a297db4a-f4c2-11e6-90f6-d3b88d6c9525
+ a297de6a-f4c2-11e6-90f7-cb6a86ce449f
+ a297deec-f4c2-11e6-90f8-c39f1ae774e5
+
+
+## 5.3 Create VGPU ##
+Use the uuid you generated to create VGPU, notes: if you want to boot up multi guests, you can use echo "uuid" > "/sys/bus/pci/devices/0000:00:02.0/mdev_supported_types/i915-GVTg_V#ID_#Type/create", like below:  
+
+> echo "a297db4a-f4c2-11e6-90f6-d3b88d6c9525" > "/sys/bus/pci/devices/0000:00:02.0/  mdev_supported_types/i915-GVTg_V4_4/create"  
+ echo "a297de6a-f4c2-11e6-90f7-cb6a86ce449f" > "/sys/bus/pci/devices/0000:00:02.0/  mdev_supported_types/i915-GVTg_V4_4/create"  
+ echo "a297deec-f4c2-11e6-90f8-c39f1ae774e5" > "/sys/bus/pci/devices/0000:00:02.0/  mdev_supported_types/i915-GVTg_V4_4/create"  
+
+Then all the vgpu directory you created can be found at "/sys/bus/pci/devices/0000:00:02.0/"
+
+## 5.4 Remove VGPU ##
+If you want to remove one vgpu you create, you need to "echo 1 > remove" at the vgpu directory and created, the example as below:
+> echo 1 > /sys/bus/pci/devices/0000:00:02.0/a297db4a-f4c2-11e6-90f6-d3b88d6c9525/remove
+
+If you want remove all vgpu you created, you can run below command.
+> for i in /sys/bus/pci/devices/0000:00:02.0/*/remove; do echo 1 > $i; done
+
+## 5.5 Network Bridge ##
+
+In order to let guest using the same network segment as host, you must create the network bridge. Besides, in order to let Qemu using the network bridge you created, you also need create a scripte as below (We saved it at /etc/qemu-ifup):
+
+Detail you can reference the the "Configuring Guest Networking" wiki page http://www.linux-kvm.org/page/Networking
+
+## 5.6 Create VM ##
+We sugguest to use the secondary gfx card mode (virtual "qxl" or "cirrus" gfx card as 1st guest gfx card, intel gfx card as 2nd guest gfx card)to create VM, the example of create VM script as below :
+
+    #! /bin/bash -x  
+        /usr/bin/qemu-system-x86_64 \  
+        -m 2048 -smp 2 -M pc \  
+        -name gvt-g-guest \  
+        -hda /home/img/ubuntu-1.qcow2  \  
+        -bios /usr/bin/bios.bin -enable-kvm \  
+        -net nic,macaddr=00:A1:00:00:00:1A -net tap,script=/etc/qemu-ifup \  
+        -vga qxl \  
+        -k en-us \  
+        -serial stdio \  
+        -vnc :1 \  
+        -machine kernel_irqchip=on \  
+        -global PIIX4_PM.disable_s3=1 -global PIIX4_PM.disable_s4=1 \  
+        -cpu host -usb -usbdevice tablet \  
+        -device vfio-pci,sysfsdev=/sys/bus/pci/devices/0000:00:02.0/a297db4a-f4c2-11e6-90f6-d3b88d6c9525   
+
+
+# 6 Features Supported #
+## 6.1 Highlights Features ##
+  - General:
+    * Supported Linux distributions (64bit): Ubuntu, Fedora, RHEL, SUSE, etc
+    * Supported Windows guest: Windows7 (32bit, 64bit), Windows8.1 (64bit), 
+      Windows10 RedStore (64bit)
+    * Supported total vGPU number <= 7
+    * Single display with resolution up to 1920x1080p
+  - 3D/2D: 
+    * OpenGL4.5 for Linux guest
+    * OpenGL4.4 for Windows guest
+    * DirectX9, 10, 11, 12 for Windows guest
+  - Compute:
+    * OpenCL2.0 for Windows/Linux guest
+  - Media:
+    * Intel Media Service Studio (2015R5)
+  - Remote display protocol:
+    * X11VNC for Linux guest
+    * TightVNC, HP RGS, RDP for Windows guest
+
+## 6.2 Validated Benchmarks ##
+  - 3D / 2D:  
+    * 3Dmark06, 3Dmark11, WebGL, Passmark, Unigine-tropics, Unigine-heaven, Phoronix 3D, Cairo 2D, etc
+  - Media: 
+    * Multiple thread decode/transcode for JPEG, MPEG2, H264, HEVC, VC1, VP8, etc
+  - OpenCL:
+    * LuxMark, Beignet
\ No newline at end of file
-- 
1.9.1



More information about the intel-gvt-dev mailing list