From 3aa22d52d185c8d0abae651db9119181a0a758bc Mon Sep 17 00:00:00 2001 From: superconvert Date: Sun, 16 Oct 2022 11:32:52 +0800 Subject: [PATCH] enable kerenl vkms support --- 01_build_src.sh | 1 + 03_run_qemu.sh | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/01_build_src.sh b/01_build_src.sh index b84b179..fbcd64b 100755 --- a/01_build_src.sh +++ b/01_build_src.sh @@ -203,6 +203,7 @@ if [ ! -d "linux_install" ]; then sed -i "s/# CONFIG_DRM_I915_GVT is not set/CONFIG_DRM_I915_GVT=y/" .config sed -i "s/# CONFIG_DRM_VGEM is not set/CONFIG_DRM_VGEM=y/" .config + sed -i "s/# CONFIG_DRM_VKMS is not set/CONFIG_DRM_VKMS=y/" .config sed -i "s/# CONFIG_DRM_VMWGFX is not set/CONFIG_DRM_VMWGFX=y\nCONFIG_DRM_VMWGFX_FBCON=y/" .config sed -i "s/# CONFIG_DRM_GMA500 is not set/CONFIG_DRM_GMA500=y\nCONFIG_DRM_GMA600=y\nCONFIG_DRM_GMA3600=y/" .config sed -i "s/# CONFIG_DRM_MGAG200 is not set/CONFIG_DRM_MGAG200=y/" .config diff --git a/03_run_qemu.sh b/03_run_qemu.sh index df00ecd..16d355f 100755 --- a/03_run_qemu.sh +++ b/03_run_qemu.sh @@ -105,10 +105,10 @@ logfile="-serial file:./qemu.log" network="-netdev tap,id=nd0,ifname=tap0,script=no,downscript=no -device e1000,netdev=nd0" # 显卡参数 需要编译 xf86-video-vmware, see mk_xfce.sh -display="-vga qxl" +display="-vga vmware" # 启动镜像 网络对应 run_nat.sh 里面的配置 ( -enable-kvm : vmware 里面 CPU 设置需要支持虚拟化 Intel VT-x/EPT 或 AMD-V/RVI ) # 命令 qemu-system-x86_64 -device help 可以查看支持哪些设备 -qemu-system-x86_64 ${display} -device qxl ${memory} ${disk} ${sdb_img} ${network} ${logfile} +qemu-system-x86_64 -enable-kvm -display sdl,gl=on -vga virtio ${memory} ${disk} ${sdb_img} ${network} ${logfile} # stop nat stop_nat