Commit 0e4e12d
committed
KVM: guest_memfd: make kvm_gmem_prepare_folio() operate on a single struct kvm
JIRA: https://issues.redhat.com/browse/RHEL-32435
This is now possible because preparation is done by kvm_gmem_get_pfn()
instead of fallocate(). In practice this is not a limitation, because
even though guest_memfd can be bound to multiple struct kvm, for
hardware implementations of confidential computing only one guest
(identified by an ASID on SEV-SNP, or an HKID on TDX) will be able
to access it.
In the case of intra-host migration (not implemented yet for SEV-SNP,
but we can use SEV-ES as an idea of how it will work), the new struct
kvm inherits the same ASID and preparation need not be repeated.
Reviewed-by: Michael Roth <michael.roth@amd.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
(cherry picked from commit 6dd761d)
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Conflicts: private_list vs. i_private_list1 parent fd6fc08 commit 0e4e12d
1 file changed
+19
-30
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | | - | |
32 | | - | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
33 | 35 | | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
| 36 | + | |
| 37 | + | |
57 | 38 | | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
58 | 47 | | |
| 48 | + | |
59 | 49 | | |
60 | 50 | | |
61 | 51 | | |
| |||
65 | 55 | | |
66 | 56 | | |
67 | 57 | | |
68 | | - | |
| 58 | + | |
69 | 59 | | |
70 | 60 | | |
71 | 61 | | |
| |||
95 | 85 | | |
96 | 86 | | |
97 | 87 | | |
98 | | - | |
99 | | - | |
| 88 | + | |
100 | 89 | | |
101 | 90 | | |
102 | 91 | | |
| |||
623 | 612 | | |
624 | 613 | | |
625 | 614 | | |
626 | | - | |
| 615 | + | |
627 | 616 | | |
628 | 617 | | |
629 | 618 | | |
| |||
0 commit comments