STRUCT OPTEE_MSG_PARAM(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct optee_msg_param(9) β€” Kernel API Manual πŸŽ€

okay bestie, welcome to the glow-up era of kernel docs. this is the page for struct optee_msg_param, which is literally the parameter struct you use together with struct optee_msg_arg. they're a package deal, iykyk 🫢


✨ NAME ✨

struct optee_msg_param β€” the parameter that gets used together with struct optee_msg_arg, fr fr πŸ’–


🌸 SYNOPSIS 🌸

here's the whole vibe, verbatim, no cap:

struct optee_msg_param {
    u64 attr;
    union {
      struct optee_msg_param_tmem tmem;
      struct optee_msg_param_rmem rmem;
      struct optee_msg_param_fmem fmem;
      struct optee_msg_param_value value;
      u8 octets[24];
    } u;
 };

look at her. iconic. the union is doing main character energy and we love that for her πŸ‘‘


πŸ¦‹ Members πŸ¦‹

  • attr β€” the attributes, bestie. this is the field that tells you what kind of thing you're looking at πŸ’…
  • u β€” the union that holds the OP-TEE msg parameter. she's flexible, she contains multitudes, she's literally holding all the possibilities at once πŸŽ€

⭐ Description ⭐

okay so here's the tea, and this part actually matters so pay attention πŸ™ˆ

attr & OPTEE_MSG_ATTR_TYPE_MASK is what tells you if tmem, rmem, or value is the one being used in the union. it's the vibe check for the whole struct, honestly.

  • OPTEE_MSG_ATTR_TYPE_VALUE_* β†’ means it's value or octets
  • OPTEE_MSG_ATTR_TYPE_TMEM_* β†’ means it's tmem
  • OPTEE_MSG_ATTR_TYPE_RMEM_* or the alias PTEE_MSG_ATTR_TYPE_FMEM_* β†’ means it's rmem or fmem, depending on the conduit
  • OPTEE_MSG_ATTR_TYPE_NONE β†’ means literally none of the members are used. she's empty. she's resting. respect it 😌
heads up bestie: don't just assume which union member is live β€” the attr mask is the only thing that tells you. and for the RMEM_* / FMEM_* situation, the conduit is what decides. no guessing πŸ”₯

πŸ‘‘ SEE ALSO πŸ‘‘

go read these next, they're all in the same friend group:

  • Kernel file ./drivers/tee/optee/optee_msg.h struct
  • struct optee_msg_param_tmem(9)
  • struct optee_msg_param_rmem(9)
  • struct optee_msg_param_fmem(9)
  • struct optee_msg_param_value(9)
  • struct optee_msg_arg(9)
  • OPTEE_MSG_GET_ARG_SIZE(9)

and that's the whole page, bestie, you ate πŸ’…βœ¨ this came to you from ./drivers/tee/optee, dated October 2026 β€” mwah, go slay your driver code πŸ§šπŸ’œ

πŸ“¦ where this page comes from