Skip to content

Commit

Permalink
mshv-bindings: implement send for svm_ghcb_base
Browse files Browse the repository at this point in the history
Signed-off-by: Muminul Islam <[email protected]>
  • Loading branch information
russell-islam committed Nov 13, 2024
1 parent 29738f9 commit 37771ac
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mshv-bindings/src/x86_64/snp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -773,6 +773,10 @@ pub struct svm_ghcb_base {
pub shared: [__u64; 254usize],
}

// SAFETY: struct is based on GHCB page in the hypervisor,
// safe to send across threads
unsafe impl Send for svm_ghcb_base {}

#[test]
fn bindgen_test_layout_svm_ghcb_base() {
const UNINIT: ::std::mem::MaybeUninit<svm_ghcb_base> = ::std::mem::MaybeUninit::uninit();
Expand Down

0 comments on commit 37771ac

Please sign in to comment.