summaryrefslogtreecommitdiffstats
path: root/spec/acfg/val/scheduler-edf-smp.yml
blob: 555070aa510052f3b16ee4193a78b8c4bd60f241 (plain) (blame)
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
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
copyrights:
- Copyright (C) 2022 embedded brains GmbH (http://www.embedded-brains.de)
enabled-by: RTEMS_SMP
links: []
test-actions:
- action-brief: |
    Check the effect of application configuration options.
  action-code: |
    rtems_status_code sc;
    uint32_t          yield_count_before;
  checks:
  - brief: |
      Check that the Earliest Deadline First SMP Scheduler which was configured
      by the ${/acfg/if/scheduler-edf-smp:/name} application configuration in
      the test suite.
    code: |
      yield_count_before = yield_count;
      sc = rtems_task_wake_after( RTEMS_YIELD_PROCESSOR );
      T_rsc_success( sc );
      T_eq_u32( yield_count, yield_count_before + 1 );
    links:
    - role: validation
      uid: ../req/scheduler-edf-smp
  links: []
test-brief: |
  Tests the effect of application configuration options.
test-context: []
test-context-support: null
test-description: null
test-header: null
test-includes:
- rtems.h
- rtems/score/scheduleredfsmp.h
test-local-includes:
- ts-config.h
- tx-support.h
test-setup: null
test-stop: null
test-support: |
  static uint32_t yield_count;

  void __real__Scheduler_EDF_SMP_Yield(
    const Scheduler_Control *scheduler,
    Thread_Control          *thread,
    Scheduler_Node          *node
  );

  void __wrap__Scheduler_EDF_SMP_Yield(
    const Scheduler_Control *scheduler,
    Thread_Control          *thread,
    Scheduler_Node          *node
  );

  void __wrap__Scheduler_EDF_SMP_Yield(
    const Scheduler_Control *scheduler,
    Thread_Control          *thread,
    Scheduler_Node          *node
  )
  {
    ++yield_count;
    __real__Scheduler_EDF_SMP_Yield( scheduler, thread, node );
  }
test-target: testsuites/validation/tc-acfg-scheduler-edf-smp.c
test-teardown: null
type: test-case