]> rtime.felk.cvut.cz Git - frescor/fosa.git/commitdiff
Adding fosa_signal_queue_scheduler() to fosa_threads_and_signals.h
authortelleriam <telleriam@35b4ef3e-fd22-0410-ab77-dab3279adceb>
Wed, 2 May 2007 17:32:37 +0000 (17:32 +0000)
committertelleriam <telleriam@35b4ef3e-fd22-0410-ab77-dab3279adceb>
Wed, 2 May 2007 17:32:37 +0000 (17:32 +0000)
git-svn-id: http://www.frescor.org/private/svn/frescor/fosa/trunk@393 35b4ef3e-fd22-0410-ab77-dab3279adceb

include/fosa_threads_and_signals.h

index c332ce4bd0fa770eda0e14cda133db38fd24936e..b958a6af451b5c7ca2420452bdbe92176ddee5c6 100644 (file)
@@ -370,11 +370,44 @@ int fosa_set_accepted_signals(frsh_signal_t set[], int size);
  * notify it to the system console and then terminate the FRSH
  * implementation and dependant applications
  **/
- int fosa_signal_queue
+int fosa_signal_queue
        (frsh_signal_t signal, frsh_signal_info_t info,
         frsh_thread_id_t receiver);
 
 
+/**
+ * fosa_signal_queue_scheduler()
+ *
+ * Queue a signal destinated to the scheduler
+ *
+ * This is a special case of fosa_signal_queue() in which the
+ * destinator is the scheduler itself.  It is needed by the service
+ * thread to notify the results to the scheduler.
+ *
+ * The problem with this case is that, depending on the implementation,
+ * this call would be translated to a true signal or to a scheduler
+ * notification message.
+ *
+ * Besides for the scheduler we don't have always a destinator
+ * thread_id needed in frsh_signal_queue for OSE.
+ *
+ * So the fosa implementation will solve this issue internally.
+ * 
+ * Returns 0 if successful; otherwise it returns an error code:
+ *     EINVAL: the signal specified by signal is not
+ *              between FOSA_SIGNAL_MIN and FOSA_SIGNAL_MAX
+ *
+ *     EAGAIN: no resources are available to queue the signal; the
+ *             maximum number of queued signals has been reached, or a
+ *             systemwide resource limit has been exceeded
+ *
+ * Alternatively, in case of error the implementation is allowed to
+ * notify it to the system console and then terminate the FRSH
+ * implementation and dependant applications
+ **/
+int fosa_signal_queue_scheduler(frsh_signal_t signal, frsh_signal_info_t info);
+
+
 /**
  * fosa_signal_wait()
  *