_kvm_s390_lo...to_effective(9)
π NAME
_kvm_s390_logical_to_effective β okay so this one converts a guest logical address into an effective address, and honestly? it's giving "tiny function, big s390 energy" β¨
(this lives in the Kernel API Manual, bestie β that's the whole vibe of the page π)
πΈ SYNOPSIS
unsigned long _kvm_s390_logical_to_effective (psw_t *psw , unsigned long
ga );
π¦ ARGUMENTS
pswβ the guest's PSW, like, the whole personality profile we're reading the addressing-mode bits out of πgaβ the guest logical address. the address in question. the main character fr fr
β¨ DESCRIPTION
So here's the tea β: this function takes a guest logical address and turns it into an effective address by applying the rules of whichever addressing mode is defined by bits 31 and 32 of the PSW you handed it (that's the extended/basic addressing mode situation, iykyk).
Depending on the addressing mode, a whole bunch of the top bits of ga get zeroed out, and the remaining bits are what comes back to you π«Ά:
- 24 bit addressing mode β the upper 40 bits get zeroed π
- 31 bit addressing mode β the upper 33 bits get zeroed
- 64 bit addressing mode β literally no bits get zeroed, nothing happens, she's untouched π
the rest of the bits? returned to you, unchanged, slay π
π₯ SEE ALSO
the kernel file lives at ./arch/s390/kvm/s390/gaccess.h, and it's surrounded by absolute icons, no cap:
kvm_s390_real_to_abs(9)kvm_s390_logical_to_effective(9)put_guest_lc(9)write_guest_lc(9)read_guest_lc(9)write_guest_with_key(9)write_guest(9)read_guest_with_key(9)read_guest(9)read_guest_instr(9)write_guest_abs(9)read_guest_abs(9)write_guest_real(9)read_guest_real(9)
bestie reminder: this is <pink>no cap</pink> territory β the bit-zeroing depends entirely on those PSW bits 31 and 32, so don't come for me if you feed it the wrong mode π
okay that's the whole page!! brought to you by ./arch/s390/kvm/s390 and dated October 2026 β periodt, go convert some addresses π
β¨
π¦ 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