source: rtems/testsuites/smptests/smpfatal04/init.c @ c5831a3f

4.115
Last change on this file since c5831a3f was c5831a3f, checked in by Sebastian Huber <sebastian.huber@…>, on 04/09/14 at 13:07:54

score: Add clustered/partitioned scheduling

Clustered/partitioned scheduling helps to control the worst-case
latencies in the system. The goal is to reduce the amount of shared
state in the system and thus prevention of lock contention. Modern
multi-processor systems tend to have several layers of data and
instruction caches. With clustered/partitioned scheduling it is
possible to honour the cache topology of a system and thus avoid
expensive cache synchronization traffic.

We have clustered scheduling in case the set of processors of a system
is partitioned into non-empty pairwise-disjoint subsets. These subsets
are called clusters. Clusters with a cardinality of one are partitions.
Each cluster is owned by exactly one scheduler instance.

  • Property mode set to 100644
File size: 1.4 KB
Line 
1/*
2 * Copyright (c) 2014 embedded brains GmbH.  All rights reserved.
3 *
4 *  embedded brains GmbH
5 *  Dornierstr. 4
6 *  82178 Puchheim
7 *  Germany
8 *  <rtems@embedded-brains.de>
9 *
10 * The license and distribution terms for this file may be
11 * found in the file LICENSE in this distribution or at
12 * http://www.rtems.org/license/LICENSE.
13 */
14
15#ifdef HAVE_CONFIG_H
16  #include "config.h"
17#endif
18
19#include <rtems.h>
20#include <rtems/test.h>
21#include <rtems/score/smpimpl.h>
22
23#include <assert.h>
24#include <stdlib.h>
25
26const char rtems_test_name[] = "SMPFATAL 4";
27
28static void Init(rtems_task_argument arg)
29{
30  assert(0);
31}
32
33static void fatal_extension(
34  rtems_fatal_source source,
35  bool is_internal,
36  rtems_fatal_code code
37)
38{
39  rtems_test_begink();
40
41  if (
42    source == RTEMS_FATAL_SOURCE_SMP
43      && !is_internal
44      && code == SMP_FATAL_BOOT_PROCESSOR_NOT_ASSIGNED_TO_SCHEDULER
45  ) {
46    rtems_test_endk();
47  }
48}
49
50#define CONFIGURE_APPLICATION_DOES_NOT_NEED_CLOCK_DRIVER
51#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
52
53#define CONFIGURE_INITIAL_EXTENSIONS \
54  { .fatal = fatal_extension }, \
55  RTEMS_TEST_INITIAL_EXTENSION
56
57#define CONFIGURE_SMP_APPLICATION
58
59#define CONFIGURE_SMP_MAXIMUM_PROCESSORS 1
60
61#define CONFIGURE_SCHEDULER_CONTROLS
62
63#define CONFIGURE_SMP_SCHEDULER_ASSIGNMENTS RTEMS_SCHEDULER_ASSIGN_NO_SCHEDULER
64
65#define CONFIGURE_MAXIMUM_TASKS 1
66
67#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
68
69#define CONFIGURE_INIT
70
71#include <rtems/confdefs.h>
Note: See TracBrowser for help on using the repository browser.