tpm_get_random(9)
π tpm_get_random(9) β the kernel API manual, but make it cute π
okay so bestie, welcome to the tpm_get_random page from the Kernel API Manual β¨ this one is short and sweet: it's literally the function that asks your TPM for random bytes. no cap, that's the whole vibe. π
πΈ NAME πΈ
tpm_get_random β get random bytes from the TPM's RNG π²π«
π¦ SYNOPSIS π¦
int tpm_get_random (struct tpm_chip *chip , u8 *out , size_t max );
β¨ ARGUMENTS β¨
chipβ astruct tpm_chipinstance, orNULLfor the default chip π«Ά (yes,NULLis totally valid here, it just means "bestie, use the default one")outβ the destination buffer where the random bytes go πmaxβ the max number of bytes to write tooutπ
π RETURN π
the number of random bytes read, or a negative error value π (so like, check it, fr fr)
π SEE ALSO π
- Kernel file
./drivers/char/tpm/tpm-interface.cπ tpm_calc_ordinal_duration(9)tpm_transmit(9)tpm_transmit_cmd(9)tpm_is_tpm2(9)tpm_pcr_read(9)tpm_pcr_extend(9)
lowkey a whole friend group of TPM functions right there β go say hi to them too π
and that's the page!! π this one came from the source/version line ./drivers/char/tpm and it's dated October 2026 β β so yeah, future vibes only, periodt πβ¨ hope that helped bestie, iykyk π§π
π¦ 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