source: rtems/cpukit/include/rtems/score/mpci.h @ 7b09032

5
Last change on this file since 7b09032 was 2afb22b, checked in by Chris Johns <chrisj@…>, on 12/23/17 at 07:18:56

Remove make preinstall

A speciality of the RTEMS build system was the make preinstall step. It
copied header files from arbitrary locations into the build tree. The
header files were included via the -Bsome/build/tree/path GCC command
line option.

This has at least seven problems:

  • The make preinstall step itself needs time and disk space.
  • Errors in header files show up in the build tree copy. This makes it hard for editors to open the right file to fix the error.
  • There is no clear relationship between source and build tree header files. This makes an audit of the build process difficult.
  • The visibility of all header files in the build tree makes it difficult to enforce API barriers. For example it is discouraged to use BSP-specifics in the cpukit.
  • An introduction of a new build system is difficult.
  • Include paths specified by the -B option are system headers. This may suppress warnings.
  • The parallel build had sporadic failures on some hosts.

This patch removes the make preinstall step. All installed header
files are moved to dedicated include directories in the source tree.
Let @RTEMS_CPU@ be the target architecture, e.g. arm, powerpc, sparc,
etc. Let @RTEMS_BSP_FAMILIY@ be a BSP family base directory, e.g.
erc32, imx, qoriq, etc.

The new cpukit include directories are:

  • cpukit/include
  • cpukit/score/cpu/@RTEMS_CPU@/include
  • cpukit/libnetworking

The new BSP include directories are:

  • bsps/include
  • bsps/@RTEMS_CPU@/include
  • bsps/@RTEMS_CPU@/@RTEMS_BSP_FAMILIY@/include

There are build tree include directories for generated files.

The include directory order favours the most general header file, e.g.
it is not possible to override general header files via the include path
order.

The "bootstrap -p" option was removed. The new "bootstrap -H" option
should be used to regenerate the "headers.am" files.

Update #3254.

  • Property mode set to 100644
File size: 4.1 KB
Line 
1/**
2 * @file
3 *
4 * @ingroup ScoreMPCI
5 *
6 * @brief MPCI Layer API
7 */
8
9/*
10 *  COPYRIGHT (c) 1989-2009.
11 *  On-Line Applications Research Corporation (OAR).
12 *
13 *  The license and distribution terms for this file may be
14 *  found in the file LICENSE in this distribution or at
15 *  http://www.rtems.org/license/LICENSE.
16 */
17
18#ifndef _RTEMS_SCORE_MPCI_H
19#define _RTEMS_SCORE_MPCI_H
20
21#include <rtems/score/mppkt.h>
22#include <rtems/score/thread.h>
23#include <rtems/score/threadq.h>
24#include <rtems/score/watchdog.h>
25
26#ifdef __cplusplus
27extern "C" {
28#endif
29
30/**
31 *  @defgroup ScoreMPCI MPCI Handler
32 *
33 *  @ingroup Score
34 *
35 *  The MPCI Handler encapsulates functionality which is related to the
36 *  generation, receipt, and processing of remote operations in a
37 *  multiprocessor system.  This handler contains the message passing
38 *  support for making remote service calls as well as the server thread
39 *  which processes requests from remote nodes.
40*/
41/**@{*/
42
43/**
44 *  The following defines the node number used when a broadcast is desired.
45 */
46#define MPCI_ALL_NODES 0
47
48/**
49 *  This type is returned by all user provided MPCI routines.
50 */
51typedef void MPCI_Entry;
52
53/**
54 *  This type defines the prototype for the initization entry point
55 *  in an Multiprocessor Communications Interface.
56 */
57typedef MPCI_Entry ( *MPCI_initialization_entry )( void );
58
59/**
60 *  This type defines the prototype for the get packet entry point
61 *  in an Multiprocessor Communications Interface.  The single
62 *  parameter will point to the packet allocated.
63 */
64typedef MPCI_Entry ( *MPCI_get_packet_entry )(
65                     MP_packet_Prefix **
66                   );
67
68/**
69 *  This type defines the prototype for the return packet entry point
70 *  in an Multiprocessor Communications Interface.  The single
71 *  parameter will point to a packet previously allocated by the
72 *  get packet MPCI entry.
73 */
74typedef MPCI_Entry ( *MPCI_return_packet_entry )(
75                     MP_packet_Prefix *
76                   );
77
78/**
79 *  This type defines the prototype for send get packet entry point
80 *  in an Multiprocessor Communications Interface.  The single
81 *  parameter will point to a packet previously allocated by the
82 *  get packet entry point that has been filled in by the caller.
83 */
84typedef MPCI_Entry ( *MPCI_send_entry )(
85                     uint32_t,
86                     MP_packet_Prefix *
87                   );
88
89/**
90 *  This type defines the prototype for the receive packet entry point
91 *  in an Multiprocessor Communications Interface.  The single
92 *  parameter will point to a packet allocated and filled in by the
93 *  receive packet handler.  The caller will block until a packet is
94 *  received.
95 */
96typedef MPCI_Entry ( *MPCI_receive_entry )(
97                     MP_packet_Prefix **
98                   );
99
100/**
101 *  This type defines the Multiprocessor Communications
102 *  Interface (MPCI) Table.  This table defines the user-provided
103 *  MPCI which is a required part of a multiprocessor system.
104 *
105 *  For non-blocking local operations that become remote operations,
106 *  we need a timeout.  This is a per-driver timeout: default_timeout
107 */
108typedef struct {
109  /** This fields contains the timeout for MPCI operations in ticks. */
110  uint32_t                   default_timeout;
111  /** This field contains the maximum size of a packet supported by this
112   *  MPCI layer.  This size places a limit on the size of a message
113   *  which can be transmitted over this interface.
114   **/
115  size_t                     maximum_packet_size;
116  /** This field points to the MPCI initialization entry point. */
117  MPCI_initialization_entry  initialization;
118  /** This field points to the MPCI get packet entry point. */
119  MPCI_get_packet_entry      get_packet;
120  /** This field points to the MPCI return packet entry point. */
121  MPCI_return_packet_entry   return_packet;
122  /** This field points to the MPCI send packet entry point. */
123  MPCI_send_entry            send_packet;
124  /** This field points to the MPCI receive packet entry point. */
125  MPCI_receive_entry         receive_packet;
126} MPCI_Control;
127
128/**@}*/
129
130#ifdef __cplusplus
131}
132#endif
133
134#endif
135/* end of include file */
Note: See TracBrowser for help on using the repository browser.