I'm browsing the Application Event Manager code, and I'm wondering:
I see that struct event_type has (effectively) an array of struct event_subscriber, bounded by pointers .subs_start and .subs_stop.
And, I see that when an event is submitted (using EVENT_SUBMIT()), work function event_processor_fn() walks this array, and calls the listener handler function for each subscriber.
What I don't see is where/how the array is populated with event_subscriber objects - where/how the objects are added onto the array.
I see macro EVENT_SUBSCRIBE(), which defines an event_subscriber object, but I don't see where/how that object is placed in the event_subscriber array for the corresponding event_type.
Thanks!