kvm_vcpu_exit_request(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ kvm_vcpu_exit_request ✨

okay bestie, welcome to the kvm_vcpu_exit_request page from the Kernel API Manual β€” yes that's the manual name, and yes it's giving "official but make it cute" πŸ’…

This one's a little function that tells you whether the VCPU should not enter the guest, like, at all. Not today, guest. πŸšͺ✨


🌸 SYNOPSIS 🌸

bool kvm_vcpu_exit_request (struct kvm_vcpu *vcpu , int *ret );

that's the whole signature, no cap β€” it takes two things and hands you back a bool 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • vcpu β€” the VCPU pointer, literally just the pointer to the VCPU we're vibing about πŸ¦‹
  • ret β€” a pointer where the optional return code gets written. optional, bestie, remember that word πŸ‘€

🌈 RETURN 🌈

returns true if the VCPU needs to bail back to a preemptible + interruptible state and skip guest entry. that's the whole vibe check βœ…


πŸ’– DESCRIPTION πŸ’–

so here's the tea, and it's actually iconic: this function disambiguates between two different types of exits 🧚

  1. exits to a preemptible + interruptible kernel context
  2. exits to userspace

for an exit to userspace, this function will write the return code to ret and return true. 🎯

for an exit to preemptible + interruptible kernel context β€” i.e. check for pending work and re-enter β€” it returns true without writing to ret. no touchy the ret, periodt πŸš«πŸ’…

so if you're staring at ret wondering why nothing landed there: it might just be the second kind of exit. check before you assume, iykyk 😭

πŸ¦‹ SEE ALSO πŸ¦‹


and that's the page fr fr πŸ’œ this one lives in ./arch/arm64/kvm and it's dated October 2026 β€” so mark your calendar bestie, slay πŸŽ€β­πŸ’€

πŸ“¦ where this page comes from