1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
|
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
copyrights:
- Copyright (C) 2022 embedded brains GmbH & Co. KG
enabled-by: RTEMS_SMP
links: []
test-actions:
- action-brief: |
Validate the home scheduler of tasks created by ${../if/create:/name} and
constructed by ${../if/construct:/name} on scheduler B.
action-code: |
rtems_status_code sc;
rtems_status_code id;
checks:
- brief: |
Move runner from scheduler A to B.
code: |
T_step_eq_u32( ${.:/step}, GetSelfScheduler(), SCHEDULER_A_ID );
SetSelfScheduler( SCHEDULER_B_ID, 1 );
links: []
- brief: |
Create a task. Check that the home scheduler of the created task is
scheduler B.
code: |
sc = rtems_task_create(
OBJECT_NAME,
1,
TEST_MINIMUM_STACK_SIZE,
RTEMS_DEFAULT_MODES,
RTEMS_DEFAULT_ATTRIBUTES,
&id
);
T_step_rsc_success( ${.:/step}, sc );
T_step_eq_u32( ${.:/step}, GetScheduler( id ), SCHEDULER_B_ID );
DeleteTask( id );
links:
- role: validation
uid: ../req/create-home-scheduler
- brief: |
Construct a task. Check that the home scheduler of the constructed task
is scheduler B.
code: |
sc = rtems_task_construct( &DefaultTaskConfig, &id );
T_step_rsc_success( ${.:/step}, sc );
T_step_eq_u32( ${.:/step}, GetScheduler( id ), SCHEDULER_B_ID );
DeleteTask( id );
links:
- role: validation
uid: ../req/construct-home-scheduler
- brief: |
Restore runner scheduler.
code: |
RestoreRunnerScheduler();
links: []
links: []
test-brief: |
This test case collection provides SMP-specific validation test cases for
requirements of the ${../if/group:/name}.
test-context: []
test-context-support: null
test-description: null
test-header: null
test-includes:
- rtems.h
test-local-includes:
- ts-config.h
- tx-support.h
test-setup: null
test-stop: null
test-support: null
test-target: testsuites/validation/tc-task-smp.c
test-teardown: null
type: test-case
|