qcom_scm_import_ice_key(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… qcom_scm_import_ice_key β€” Kernel API Manual ✨

okay bestie, so we're in the Kernel API Manual today and the star of the show is qcom_scm_import_ice_key(9) β€” yes it's a mouthful, yes it slays, let's get into it πŸŽ€


✨ NAME ✨

qcom_scm_import_ice_key β€” the one that imports your key for storage encryption πŸ”πŸ’–


πŸ¦‹ SYNOPSIS πŸ¦‹

int qcom_scm_import_ice_key (const u8 *raw_key , size_t raw_key_size ,
u8 *lt_key , size_t lt_key_size );

that's the whole vibe check right there β€” one int coming back at you, four args going in πŸ‘‘


🌸 ARGUMENTS 🌸

  • raw_key β€” the raw key you're importing, the actual main character of this operation πŸ’«
  • raw_key_size β€” how big raw_key is, in bytes. yes, bytes, we measure things here πŸ“
  • lt_key β€” your output buffer, where the long-term wrapped key gets to live 🏑✨
  • lt_key_size β€” size of lt_key in bytes, and listen β€” it must be the exact wrapped key size that the SoC uses. not close, not approximate, exact. the SoC is not flexible about this and honestly respect 😭

πŸ’œ DESCRIPTION πŸ’œ

So what does it do? It imports a raw key and hands you back a long-term wrapped key. That's it, that's the plot 🫢

Under the hood it uses the SoC's HWKM to wrap the raw key using the platform-specific Key Encryption Key β€” hardware doing hardware things, no cap πŸ”₯πŸ’…


⭐ RETURN ⭐

0 on success, -errno on failure. iconic behavior, no notes πŸ™ˆπŸ’–


🌈 SEE ALSO 🌈

the whole friend group, and they all showed up to the group chat πŸ‘‘

Kernel file ./drivers/firmware/qcom/qcom_scm.c, plus:


aaaand that's the page, bestie πŸ§šπŸ’œ this one lives in ./drivers/firmware/qcom and it's dated October 2026 β€” so yeah, future-coded of it βœ¨πŸ¦‹ go forth and import those keys responsibly, mwah πŸ’‹πŸŽ€

πŸ“¦ where this page comes from