STRUCT SEV_USER_DATA_SNP_STATUS(9)
π struct sev_user_data_snp_status(9) π
okay so this is a page from the Kernel API Manual, and bestie, it's literally the glow-up tour of struct sev_user_data_snp_status β the SNP status struct, no cap. It's giving "firmware receipts, but make it a C struct" β¨
πΈ NAME πΈ
struct sev_user_data_snp_status β SNP status. that's it, that's the whole vibe check π
β¨ SYNOPSIS β¨
struct sev_user_data_snp_status {
__u8 api_major;
__u8 api_minor;
__u8 state;
__u8 is_rmp_initialized:1;
__u8 rsvd:7;
__u32 build_id;
__u32 mask_chip_id:1;
__u32 mask_chip_key:1;
__u32 vlek_en:1;
__u32 feature_info:1;
__u32 rapl_dis:1;
__u32 ciphertext_hiding_cap:1;
__u32 ciphertext_hiding_en:1;
__u32 rsvd1:25;
__u32 guest_count;
__u64 current_tcb_version;
__u64 reported_tcb_version;
};
like, look at all those bitfields. the way they packed everything in there? iconic. bitfield packing is so main character energy π
π¦ Members π¦
okay so let's go through every single member one by one, because we do NOT skip details in this house π«Ά
api_majorβ the API major version. the big number. the "era" of the API, iykyk πapi_minorβ the API minor version. the little number that rides along with the major one β¨stateβ the current platform state. where the platform is at, emotionally. (no but fr, it's the current platform state) πis_rmp_initializedβ whether RMP is initialized or not. one single bit deciding its whole fate πrsvdβ reserved. do not touch, she's not for you πbuild_idβ the firmware build id for the API version. the firmware's birth certificate fr fr π¦mask_chip_idβ whether chip id is present in attestation reports or not βmask_chip_keyβ whether attestation reports are signed or not π₯vlek_enβ VLEK (Version Loaded Endorsement Key) hashstick is loaded. yes that's the actual name. yes it's a lot. we love her anyway πfeature_infoβ whetherSNP_FEATURE_INFOcommand is available. a whole command hidden behind one bit, lowkey iconic πrapl_disβ whether RAPL is disabled πciphertext_hiding_capβ whether the platform has ciphertext hiding capability. capability, bestie, not the actual hiding β that's the next one πciphertext_hiding_enβ whether ciphertext hiding is enabled. and there's the follow-through π«rsvd1β reserved. again. she's got25bits of "mind your business" πguest_countβ the number of guest currently managed by the firmware. yes, "guest", singular, that's literally what the original says, don't come for me πcurrent_tcb_versionβ current TCB version πreported_tcb_versionβ reported TCB version. two versions, one struct, they're sisters not twins π
ngl the bitfields are doing a lot of heavy lifting here and honestly? ate. no crumbs. β¨
π§ SEE ALSO π§
- Kernel file
./include/uapi/linux/psp-sev.hstruct sev_user_data_status(9)struct sev_user_data_pek_csr(9)struct sev_user_data_pdh_cert_export(9)struct sev_user_data_get_id(9)struct sev_user_data_get_id2(9)struct sev_user_data_snp_config(9)sev_issue_cmd(9)
like, go read her friends too, they're all in the same group chat π«Ά
and that's the whole page, bestie!! mwah π this little number lives in ./include/uapi/linux and it's dated October 2026 β remember us when you're deep in the bitfields, okay? slay, stay hydrated, and don't touch the reserved bits πβ¨π
π¦ 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