Lines Matching refs:event_num
54 u32 event_num; member
166 static struct sdei_event *sdei_event_find(u32 event_num) in sdei_event_find() argument
174 if (e->event_num == event_num) { in sdei_event_find()
197 static struct sdei_event *sdei_event_create(u32 event_num, in sdei_event_create() argument
215 event->event_num = event_num; in sdei_event_create()
217 err = sdei_api_event_get_info(event_num, SDEI_EVENT_INFO_EV_PRIORITY, in sdei_event_create()
223 err = sdei_api_event_get_info(event_num, SDEI_EVENT_INFO_EV_TYPE, in sdei_event_create()
236 reg->event_num = event->event_num; in sdei_event_create()
255 reg->event_num = event->event_num; in sdei_event_create()
382 static int sdei_api_event_enable(u32 event_num) in sdei_api_event_enable() argument
384 return invoke_sdei_fn(SDEI_1_0_FN_SDEI_EVENT_ENABLE, event_num, 0, 0, 0, in sdei_api_event_enable()
394 err = sdei_api_event_enable(arg->event->event_num); in _local_event_enable()
399 int sdei_event_enable(u32 event_num) in sdei_event_enable() argument
405 event = sdei_event_find(event_num); in sdei_event_enable()
414 err = sdei_api_event_enable(event->event_num); in sdei_event_enable()
429 static int sdei_api_event_disable(u32 event_num) in sdei_api_event_disable() argument
431 return invoke_sdei_fn(SDEI_1_0_FN_SDEI_EVENT_DISABLE, event_num, 0, 0, in sdei_api_event_disable()
440 err = sdei_api_event_disable(arg->event->event_num); in _ipi_event_disable()
445 int sdei_event_disable(u32 event_num) in sdei_event_disable() argument
451 event = sdei_event_find(event_num); in sdei_event_disable()
462 err = sdei_api_event_disable(event->event_num); in sdei_event_disable()
470 static int sdei_api_event_unregister(u32 event_num) in sdei_api_event_unregister() argument
472 return invoke_sdei_fn(SDEI_1_0_FN_SDEI_EVENT_UNREGISTER, event_num, 0, in sdei_api_event_unregister()
482 err = sdei_api_event_unregister(arg->event->event_num); in _local_event_unregister()
487 int sdei_event_unregister(u32 event_num) in sdei_event_unregister() argument
495 event = sdei_event_find(event_num); in sdei_event_unregister()
497 pr_warn("Event %u not registered\n", event_num); in sdei_event_unregister()
508 err = sdei_api_event_unregister(event->event_num); in sdei_event_unregister()
537 err = sdei_api_event_unregister(event->event_num); in sdei_unregister_shared()
547 static int sdei_api_event_register(u32 event_num, unsigned long entry_point, in sdei_api_event_register() argument
550 return invoke_sdei_fn(SDEI_1_0_FN_SDEI_EVENT_REGISTER, event_num, in sdei_api_event_register()
563 err = sdei_api_event_register(arg->event->event_num, sdei_entry_point, in _local_event_register()
569 int sdei_event_register(u32 event_num, sdei_event_callback *cb, void *arg) in sdei_event_register() argument
577 if (sdei_event_find(event_num)) { in sdei_event_register()
578 pr_warn("Event %u already registered\n", event_num); in sdei_event_register()
583 event = sdei_event_create(event_num, cb, arg); in sdei_event_register()
586 pr_warn("Failed to create event %u: %d\n", event_num, err); in sdei_event_register()
592 err = sdei_api_event_register(event->event_num, in sdei_event_register()
604 pr_warn("Failed to register event %u: %d\n", event_num, err); in sdei_event_register()
630 err = sdei_api_event_register(event->event_num, in sdei_reregister_shared()
635 event->event_num); in sdei_reregister_shared()
642 err = sdei_api_event_enable(event->event_num); in sdei_reregister_shared()
645 event->event_num); in sdei_reregister_shared()
670 event->event_num, err); in sdei_cpuhp_down()
693 event->event_num, err); in sdei_cpuhp_up()
701 event->event_num, err); in sdei_cpuhp_up()
861 u32 event_num; in sdei_register_ghes() local
867 event_num = ghes->generic->notify.vector; in sdei_register_ghes()
868 if (event_num == 0) { in sdei_register_ghes()
876 err = sdei_api_event_get_info(event_num, SDEI_EVENT_INFO_EV_PRIORITY, in sdei_register_ghes()
886 err = sdei_event_register(event_num, cb, ghes); in sdei_register_ghes()
888 err = sdei_event_enable(event_num); in sdei_register_ghes()
897 u32 event_num = ghes->generic->notify.vector; in sdei_unregister_ghes() local
908 err = sdei_event_disable(event_num); in sdei_unregister_ghes()
913 err = sdei_event_unregister(event_num); in sdei_unregister_ghes()
1088 u32 event_num = arg->event_num; in sdei_event_handler() local
1090 err = arg->callback(event_num, regs, arg->callback_arg); in sdei_event_handler()
1093 event_num, smp_processor_id(), err); in sdei_event_handler()