[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [XEN PATCH v1 13/15] x86: wire cpu_has_{svm/vmx}_* to false when svm/vmx not enabled


  • To: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • From: Sergiy Kibrik <sergiy_kibrik@xxxxxxxx>
  • Date: Thu, 18 Apr 2024 16:31:04 +0300
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=epam.com; dmarc=pass action=none header.from=epam.com; dkim=pass header.d=epam.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=HirSd0t5+EnyK16DnRJY1QL7GZUZgFHV+Bic5BSOBpE=; b=ax5y6AF1R7SYJl+CmKOngCbor0GKibzmIq5hVLvQWIWI0vorA4L1QJD6Y73nHNHdOqwqiytRBR8KxEZ402sCq+NgEvenBCUShooVPiRaVAEjQvxqV7lc8YVudcYG4ILksm8E/yF9r6DYlVY2PaDgfp3HIfRh0Uld03v3wEAVHtZv2eR9OPyni0q5r2cmnrbFqY5KdPkOaaexuonvpnDm9ZRVKxFMOp+aQJDvkaNf4hjvDgRFIVFp0LhxU8hm1Ah6YSs0/aPJduVASSM2fYcNKK2oAfaGCl41c+U2+EFCPtSlLOm/pCefvm2LB90Z0CmHWmQhk/f1tuGZ7FJ4lHFCYw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kXU8Dj74MzkoS9cIvbYAFQoEw2M7EbHIhWedravLMlhEpP+ZLSAGH0PfiqxQ1E8Ux0n0zxofMYci6a8KhYsBnGrERMidTVbYnNfoJyFCbHavXJGNFUFvomVW3DvfbVNxBKbnJ5O3e8pWHhPM2Gs8g6ndIQJk2p9XMpvzE69Bm+mqTZp2Yu0uhMola40xILkKjRyaJmLIW/I//onha2DWX2z/fQKr9/Vm+gK2ys80wRS4UZhSi4ek2cUjDCNi3QUNDfgcsdVXZyah/fiuncZpTKFaidYPxYpPp3mrezSQI2hHsZHHP4RlczAdmwKB2uGC2wrXmKq43yCoAmNC4J/vxg==
  • Cc: Jan Beulich <jbeulich@xxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Xenia Ragiadakou <xenia.ragiadakou@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Thu, 18 Apr 2024 13:31:20 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

16.04.24 16:26, Andrew Cooper:
I'm afraid this is going in an unhelpful direction.  We want to move
both of these files to be local to arch/x86/hvm/{vmx,svm}/.

cpu_has_svm_* isn't actually used outside of svm/; only the plain
SVM_FEATURE_* constants are, and that's only because they're not
expressed as plain cpu features yet.

cpu_has_vmx_* has a few more users, but most are unlikely to remain in
this form.  One critical set of changes to fix vulnerabilities in
nested-virt is to make almost of of these decisions based on per-domain
state, not host state.  The aspects which are host state should be in
regular cpu features.

I already volunteered to sort out the SEV feature leaf properly, and I
was going to do the SVM leaf while I was at it.  If you can wait a few
days, I might be able to make half of this problem disappear.

I guess it can wait, surely if a better solution is to be crafted at the end.

Stefano, what's your opinion on that?

  -Sergiy



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.