STRUCT SCMI_REGISTERED_EVENT(9)
β¨ struct scmi_registered_event(9) β¨
Hey bestie! π Welcome to the glow-up of struct scmi_registered_event β this is the kernel API manual page for the struct scmi_...stered_event(9) situation, and we're about to make it make sense. No cap, it's all about Event Specific Information and it's giving main character energy. π
πΈ NAME πΈ
struct scmi_registered_event β Event Specific Information. Literally what it says on the tin, bestie. β¨
π¦ SYNOPSIS π¦
Okay so here's the whole struct in all its glory β copy it EXACTLY, no editing, periodt:
struct scmi_registered_event {
struct scmi_registered_events_desc *proto;
const struct scmi_event *evt;
void *report;
u32 num_sources;
bool not_supported_by_platform;
struct mutex sources_mtx;
refcount_t sources[];
};
π Members π
Let's break down every single member, one by one, no skipping, fr fr:
protoβ A reference to the associated protocol descriptor. It's like the protocol's little handshake partner, you know? π«±evtβ A reference to the associated event descriptor (as provided at registration time). Iconic, honestly.reportβ A pre-allocated buffer used by the deferred worker to fill a customized event report. Very demure, very mindful buffer. πnum_sourcesβ The number of possible sources for this event as stated at events' registration time. Numbers don't lie, bestie. π’not_supported_by_platformβ A flag to indicate that not even one source was found to be supported by the platform for this event. Oof, the platform said "not today" πsources_mtxβ A mutex to serialize the access tosources. It's giving bouncer at the club β one at a time, please. πͺsourcesβ A reference to a dynamically allocated array used to refcount the events' enable requests for all the existing sources. Refcount queen behavior. π
π Description π
So here's the tea: all registered events are represented by one of these structures that are stored in the registered_events array at protocol registration time. Cute, right? β¨
Once these descriptors are successfully registered, they are NEVER again removed or modified since protocols do not unregister ever β yes, you read that right, NEVER, bold and everything. So once we safely grab a NON-NULL reference from the table we can keep it and use it. It's giving permanent resident energy, and honestly? We stan a stable pointer. π
Heads up bestie: the all-caps NEVER is not me being dramatic β it's literally in the original. These things stay put. π«Ά
π₯ SEE ALSO π₯
Okay this list is LONG but we're not skipping a single one, because every reference matters, iykyk:
- Kernel file
./drivers/firmware/arm_scmi/notify.c Theory of operation(9)struct scmi_notify_instance(9)struct events_queue(9)struct scmi_event_header(9)struct scmi_registered_events_desc(9)struct scmi_event_handler(9)scmi_lookup_and_call_event_chain(9)scmi_process_event_header(9)scmi_process_event_payload(9)scmi_events_dispatcher(9)scmi_notify(9)scmi_kfifo_free(9)scmi_initialize_events_queue(9)scmi_allocate_registered_events_desc(9)scmi_register_protocol_events(9)scmi_deregister_protocol_events(9)scmi_allocate_event_handler(9)scmi_free_event_handler(9)scmi_bind_event_handler(9)scmi_valid_pending_handler(9)scmi_register_event_handler(9)__scmi_event_handler_get_ops(9)scmi_get_active_handler(9)__scmi_enable_evt(9)scmi_put_handler_unlocked(9)scmi_event_handler_enable_events(9)scmi_notifier_register(9)scmi_notifier_unregister(9)scmi_devm_notifier_register(9)scmi_devm_notifier_unregister(9)scmi_protocols_late_init(9)scmi_notification_init(9)scmi_notification_quiesce(9)scmi_notification_exit(9)
And that's the whole page, bestie! This gem lives in ./drivers/firmware/arm_scmi and it's dated October 2026 β so futuristic, so slay. π Stay curious, keep your pointers non-NULL, and remember: protocols never unregister, and neither should your love for the kernel. π§β¨
π¦ 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