lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Fri,  5 Oct 2018 11:46:05 -0700
From:   Guenter Roeck <linux@...ck-us.net>
To:     Paolo Bonzini <pbonzini@...hat.com>
Cc:     Radim Krčmář <rkrcmar@...hat.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
        x86@...nel.org, kvm@...r.kernel.org, linux-kernel@...r.kernel.org,
        Guenter Roeck <linux@...ck-us.net>,
        Brijesh Singh <brijesh.singh@....com>,
        Borislav Petkov <bp@...e.de>
Subject: [PATCH] KVM: X86: Add missing KVM_AMD dependency

Building an image with KVM_AMD=y, CRYPTO_DEV_SP_PSP=y, and
CRYPTO_DEV_CCP_DD=m fails with the following error messages.

arch/x86/kvm/svm.c:6287: undefined reference to `sev_issue_cmd_external_user'
arch/x86/kvm/svm.o: In function `sev_unbind_asid':
arch/x86/kvm/svm.c:1747: undefined reference to `sev_guest_deactivate'
arch/x86/kvm/svm.c:1750: undefined reference to `sev_guest_df_flush'
arch/x86/kvm/svm.c:1759: undefined reference to `sev_guest_decommission'

Analysis shows that commit 59414c9892208 ("KVM: SVM: Add support for
KVM_SEV_LAUNCH_START command") added a dependency of KVM_AMD on
CRYPTO_DEV_CCP_DD if CRYPTO_DEV_SP_PSP is enabled: If CRYPTO_DEV_CCP_DD
is built as module, KVM_AMD must be built as module as well.

Fixes: 59414c9892208 ("KVM: SVM: Add support for KVM_SEV_LAUNCH_START command")
Cc: Brijesh Singh <brijesh.singh@....com>
Cc: Borislav Petkov <bp@...e.de>
Signed-off-by: Guenter Roeck <linux@...ck-us.net>
---
 arch/x86/kvm/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/x86/kvm/Kconfig b/arch/x86/kvm/Kconfig
index 1bbec387d289..a8eff6910ea3 100644
--- a/arch/x86/kvm/Kconfig
+++ b/arch/x86/kvm/Kconfig
@@ -74,6 +74,7 @@ config KVM_INTEL
 config KVM_AMD
 	tristate "KVM for AMD processors support"
 	depends on KVM
+	depends on !CRYPTO_DEV_SP_PSP || (CRYPTO_DEV_SP_PSP && CRYPTO_DEV_CCP_DD)
 	---help---
 	  Provides support for KVM on AMD processors equipped with the AMD-V
 	  (SVM) extensions.
-- 
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ