The rsm_intr_signal_post() and rsm_intr_signal_wait() functions are event functions that allow synchronization between importer processes and exporter processes. A process may block to wait for an event occurance by calling rsm_intr_signal_wait(). A process can signal a waiting process when an event occurs by calling rsm_intr_signal_post().
The rsm_intr_signal_post() function signals an event occurance. Either an import segment handle (rsm_memseg_import_handle_t) or an export segment handle (rsm_memseg_export_handle_t) may be type cast to a void pointer for the memseg argument. If memseg refers to an import handle, the exporting process is signalled. If memseg refers to an export handle, all importers of that segment are signalled. The flags argument may be set to RSM_SIGPOST_NO_ACCUMULATE; this will cause this event to be discarded if an event is already pending for the target segment.
The rsm_intr_signal_wait() function allows a process to block and wait for an event occurance. Either an import segment handle (rsm_memseg_import_handle_t) or an export segment handle (rsm_memseg_export_handle_t) may be type cast to a void
pointer for the memseg argument. The process blocks for up to timeout milliseconds for an event to occur; if the timeout value is -1, the process blocks until an event occurs or until interrupted.
|