STRUCT SCMI_PROTOCOL(9)
π struct scmi_protocol(9) π
okay so bestie, welcome to the Kernel API Manual β¨ β this is the page for struct scmi_protocol(9), aka the protocol descriptor. it's literally the little ID card every SCMI protocol carries around so the kernel knows who it is, who owns it, what it can do, and what version vibes it's on. let's get into it π«Ά
β¨ NAME β¨
struct scmi_protocol β the protocol descriptor. that's it, that's the whole name. iconic behavior honestly π
π¦ SYNOPSIS π¦
here's the whole struct, copied exactly because we do not mess with source code in this house:
struct scmi_protocol {
const u8 id;
struct module *owner;
const scmi_prot_init_ph_fn_t instance_init;
const scmi_prot_init_ph_fn_t instance_deinit;
const void *ops;
const struct scmi_protocol_events *events;
unsigned int supported_version;
char *vendor_id;
char *sub_vendor_id;
u32 impl_ver;
};
look at her. all those aligned fields. the way that this struct is just organized ππ
π Members π
okay now the part you actually came for β every single member, no skips, no cap:
idβ the Protocol ID. that's the whole thing. it's the protocol's name tag π·οΈownerβ the Module reference, if there is one. no module? no problem πinstance_initβ the Mandatory protocol initialization function. mandatory mandatory β like, you literally cannot skip this one, it's giving "you must attend the group chat" energy π₯instance_deinitβ the Optional protocol de-initialization function. cleanup era, but only if you feel like it πΈopsβ an Optional reference to the operations the protocol provides, exposed over inscmi_protocol.h. this is where the protocol keeps its actual skill set β¨eventsβ an Optional reference to the events this protocol supports. notification girlies rise up πsupported_versionβ the highest version currently supported for this protocol by the agent. and here's the key bit: each protocol implementation in the agent is supposed to downgrade to match the protocol version supported by the platform. so like, dress for the platform you're actually on, not the one you wish you were on πvendor_idβ a firmware vendor string used for matching vendor protocols. β οΈ it's ignored whenididentifies a standard protocol, and it cannot be NULL otherwise. so standard protocol? ignore. vendor protocol? you better fill it in, bestie π¨sub_vendor_idβ a firmwaresub_vendorstring, also for matching vendor protocols. this one is ignored if NULL, and also ignored whenididentifies a standard protocol. so it's the chill optional one of the vendor strings π¦impl_verβ a firmware implementation version for vendor protocols matching. ignored if zero, and ignored ifididentifies a standard protocol. zero = don't care, standard protocol = don't care, otherwise it's matching time β
π Description π
quick note bestie, don't miss this one: vendor protocols matching at load time happens by attempting the closest match first against the tuple (vendor, sub_vendor, impl_ver).
so it's not a "first one wins" situation, it's a "who's the most specific" situation. the closest match gets picked first π― iykyk
π SEE ALSO π
go read these, they're all in the Kernel file ./drivers/firmware/arm_scmi/protocols.h:
struct scmi_msg_resp_prot_version(9)struct scmi_msg(9)struct scmi_msg_hdr(9)struct scmi_xfer(9)struct scmi_protocol_handle(9)struct scmi_iterator_state(9)struct scmi_iterator_ops(9)struct scmi_proto_helpers_ops(9)struct scmi_xfer_ops(9)
that's the whole friend group right there, go say hi π
and that's the page!! π this little cutie lives in ./drivers/firmware/arm_scmi, it's dated October 2026, and it's filed under struct scmi_protocol(9) in the Kernel API Manual. slay, go read some source, mwah π
πβ¨
π¦ 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