kvm_s390_pv_deinit_vm(9)
β¨ kvm_s390_pv_deinit_vm(9) β¨
okay bestie so like, welcome to the Kernel API Manual π we're doing kvm_s390_pv_deinit_vm(9) today and honestly? it's giving cleanup era. it's giving "we're so done here". no cap, let's get into it π«Ά
πΈ NAME πΈ
kvm_s390_pv_deinit_vm β deinitialize the current protected VM β¨ (yep, that's the whole thing, she's literally that simple π
)
π SYNOPSIS π
int kvm_s390_pv_deinit_vm (struct kvm *kvm , u16 *rc , u16 *rrc );
π¦ ARGUMENTS π¦
kvmβ the KVM whose protected VM needs to be deinitialized. like this is THE vm, the main character of the operation πrcβ the RC code of the UVC. important little guy πrrcβ the RRC code of the UVC. his bestie, also important π
π DESCRIPTION π
so what this does is deinitialize the current protected VM. she will destroy and cleanup the current protected VM β like fully closing the tab, closing the whole browser β but β οΈ she will not cleanup the guest memory. that part is not her job, she said not today π
so the way this works is, you should only call this when the protected VM has just been created and therefore does not have any guest memory. OR β and this is the other vibe β when the caller cleans up the guest memory separately. so like, either it's a brand new baby VM with nothing in it, or you're handling the memory yourself on your own time. iykyk πΈ
π¨ okay this is the important part, don't skip it: this function should not fail, but if it does, the donated memory must not be freed. like i'm serious, do not free it. periodt. π₯
π§ CONTEXT π§
kvm->lock needs to be held π β like, you literally cannot do this without it, so lock it first bestie, it's a vibe check you have to pass.
β RETURN β
0 in case of success β¨ otherwise -EIO. so it's literally just the two outcomes, no in-between, no maybe π
π SEE ALSO π
okay so there's a whole little friend group here, let me introduce everyone π₯°
- kernel file
./arch/s390/kvm/s390/pv.cβ that's where she lives, that's the home address π should_export_before_import(9)kvm_s390_pv_make_secure(9)kvm_s390_pv_destroy_page(9)struct pv_vm_to_be_destroyed(9)kvm_s390_pv_dispose_one_leftover(9)kvm_s390_pv_set_aside(9)kvm_s390_pv_deinit_cleanup_all(9)kvm_s390_pv_deinit_aside_vm(9)kvm_s390_pv_dump_stor_state(9)kvm_s390_pv_dump_complete(9)
go read them, they're all icons, you're welcome π
and that's the page bestie!! π written straight out of ./arch/s390/kvm/s390 and dated October 2026 β so mark your calendars or whatever βπ mwah, go hold that lock and slay π¦β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms