Thread (18 messages) 18 messages, 3 authors, 2024-03-07

Re: [RFC RFT PATCH 1/4] hv: Leak pages if set_memory_encrypted() fails

From: "Edgecombe, Rick P" <rick.p.edgecombe@intel.com>
Date: 2024-03-01 20:47:17
Also in: linux-coco, lkml, netdev

On Fri, 2024-03-01 at 20:21 +0000, Michael Kelley wrote:
The Hyper-V case can actually be a third path when a paravisor
is being used.  In that case, for both TDX and SEV-SNP, the
hypervisor callbacks in __set_memory_enc_pgtable() go
to Hyper-V specific functions that talk to the paravisor. Those
callbacks never panic. After a failure, either at the paravisor
level or in the paravisor talking to the hypervisor/VMM, the
decrypted/encrypted state of the memory isn't known.  So
leaking the memory is still the right thing to do, and your
patch set is good. But in the Hyper-V with paravisor case,
the leaking is applicable more broadly than just TDX.

The text in the commit message isn't something that I'll
go to the mat over.  But I wanted to offer the slightly broader
perspective.
Oh, interesting. I think I missed it because it only has a special
enc_status_change_finish(). But yea. It does sound like the text you
suggested is more accurate. I'll update it.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help