mirror of
https://git.rtems.org/rtems-docs/
synced 2025-06-01 07:09:14 +08:00
c-user: Update rtems_task_set_scheduler()
This commit is contained in:
parent
ff9d55501f
commit
9260c986ce
@ -1436,7 +1436,8 @@ CALLING SEQUENCE:
|
||||
|
||||
rtems_status_code rtems_task_set_scheduler(
|
||||
rtems_id task_id,
|
||||
rtems_id scheduler_id
|
||||
rtems_id scheduler_id,
|
||||
rtems_task_priority priority
|
||||
);
|
||||
|
||||
DIRECTIVE STATUS CODES:
|
||||
@ -1447,13 +1448,20 @@ DIRECTIVE STATUS CODES:
|
||||
- successful operation
|
||||
* - ``RTEMS_INVALID_ID``
|
||||
- invalid task or scheduler id
|
||||
* - ``RTEMS_INCORRECT_STATE``
|
||||
* - ``RTEMS_INVALID_PRIORITY``
|
||||
- invalid task priority
|
||||
* - ``RTEMS_RESOURCE_IN_USE``
|
||||
- the task is in the wrong state to perform a scheduler change
|
||||
* - ``RTEMS_UNSATISFIED``
|
||||
- the processor set of the scheduler is empty
|
||||
* - ``RTEMS_ILLEGAL_ON_REMOTE_OBJECT``
|
||||
- not supported on remote tasks
|
||||
|
||||
DESCRIPTION:
|
||||
Sets the scheduler of a task identified by ``task_id`` to the scheduler
|
||||
identified by ``scheduler_id``. The scheduler of a task is initialized to
|
||||
the scheduler of the task that created it.
|
||||
the scheduler of the task that created it. The priority of the task is set
|
||||
to ``priority``.
|
||||
|
||||
NOTES:
|
||||
None.
|
||||
@ -1489,7 +1497,7 @@ EXAMPLE:
|
||||
);
|
||||
assert( sc == RTEMS_SUCCESSFUL );
|
||||
|
||||
sc = rtems_task_set_scheduler(task_id, scheduler_id);
|
||||
sc = rtems_task_set_scheduler( task_id, scheduler_id, 2 );
|
||||
assert( sc == RTEMS_SUCCESSFUL );
|
||||
|
||||
sc = rtems_task_start( task_id, task, 0 );
|
||||
|
Loading…
x
Reference in New Issue
Block a user