Linux 内核 4.16.2 无法编译

Linux 内核 4.16.2 无法编译

当我尝试编译 Linux 内核 4.16.1 和 4.16.2 时,出现以下错误:

arch/x86/kvm/svm.o: In function `__sev_issue_cmd':
svm.c:(.text+0x1f08): undefined reference to `sev_issue_cmd_external_user'
arch/x86/kvm/svm.o: In function `sev_unbind_asid':
svm.c:(.text+0x2033): undefined reference to `sev_guest_deactivate'
svm.c:(.text+0x203f): undefined reference to `sev_guest_df_flush'
svm.c:(.text+0x206c): undefined reference to `sev_guest_decommission'
arch/x86/kvm/svm.o: In function `svm_mem_enc_op':
svm.c:(.text+0x2c56): undefined reference to `psp_copy_user_blob'
svm.c:(.text+0x2d4c): undefined reference to `sev_platform_init'
svm.c:(.text+0x2e59): undefined reference to `psp_copy_user_blob'
svm.c:(.text+0x2eea): undefined reference to `sev_guest_df_flush'
svm.c:(.text+0x2f3d): undefined reference to `sev_guest_activate'
svm.c:(.text+0x3001): undefined reference to `psp_copy_user_blob'
svm.c:(.text+0x3054): undefined reference to `psp_copy_user_blob'
arch/x86/kvm/svm.o: In function `svm_hardware_setup':
svm.c:(.init.text+0x263): undefined reference to `sev_platform_status'
make: *** [Makefile:1041: vmlinux] Error 1

有人知道需要做什么来解决这个问题吗?我使用任何以前的内核版本都没有这个问题。

答案1

我需要将“基于内核的虚拟机支持”编译到内核中,而不是作为模块。一旦完成,内核编译就没有问题了。

相关内容