[rtems commit] score: Move mppkt implementation into mpciimpl.h
Sebastian Huber
sebh at rtems.org
Fri Jul 26 09:51:53 UTC 2013
Module: rtems
Branch: master
Commit: 0b9f472116eea06f17f4b481918b5d723b40cdd0
Changeset: http://git.rtems.org/rtems/commit/?id=0b9f472116eea06f17f4b481918b5d723b40cdd0
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Thu Jul 25 10:33:41 2013 +0200
score: Move mppkt implementation into mpciimpl.h
---
cpukit/score/Makefile.am | 5 --
cpukit/score/include/rtems/score/mpciimpl.h | 15 +++++++
cpukit/score/include/rtems/score/mppkt.h | 22 ++++------
cpukit/score/inline/rtems/score/mppkt.inl | 61 ---------------------------
cpukit/score/preinstall.am | 5 --
5 files changed, 24 insertions(+), 84 deletions(-)
diff --git a/cpukit/score/Makefile.am b/cpukit/score/Makefile.am
index b5ffe57..f571016 100644
--- a/cpukit/score/Makefile.am
+++ b/cpukit/score/Makefile.am
@@ -104,11 +104,6 @@ endif
include_rtems_score_HEADERS += inline/rtems/score/object.inl
include_rtems_score_HEADERS += inline/rtems/score/tod.inl
-if HAS_MP
-## We only build multiprocessing related files if HAS_MP was defined
-include_rtems_score_HEADERS += inline/rtems/score/mppkt.inl
-endif
-
## src
AM_CPPFLAGS += -D__RTEMS_INSIDE__
diff --git a/cpukit/score/include/rtems/score/mpciimpl.h b/cpukit/score/include/rtems/score/mpciimpl.h
index 29a78c1..37eb412 100644
--- a/cpukit/score/include/rtems/score/mpciimpl.h
+++ b/cpukit/score/include/rtems/score/mpciimpl.h
@@ -327,6 +327,21 @@ void _MPCI_Internal_packets_Process_packet (
*/
MPCI_Internal_packet *_MPCI_Internal_packets_Get_packet ( void );
+/**
+ * This function returns true if the the_packet_class is valid,
+ * and false otherwise.
+ *
+ * @note Check for lower bounds (MP_PACKET_CLASSES_FIRST ) is unnecessary
+ * because this enum starts at lower bound of zero.
+ */
+
+RTEMS_INLINE_ROUTINE bool _Mp_packet_Is_valid_packet_class (
+ MP_packet_Classes the_packet_class
+)
+{
+ return ( the_packet_class <= MP_PACKET_CLASSES_LAST );
+}
+
/**@}*/
#ifdef __cplusplus
diff --git a/cpukit/score/include/rtems/score/mppkt.h b/cpukit/score/include/rtems/score/mppkt.h
index 7dca306..71cb7f2 100644
--- a/cpukit/score/include/rtems/score/mppkt.h
+++ b/cpukit/score/include/rtems/score/mppkt.h
@@ -22,6 +22,14 @@
#ifndef _RTEMS_SCORE_MPPKT_H
#define _RTEMS_SCORE_MPPKT_H
+#include <rtems/score/object.h>
+#include <rtems/score/priority.h>
+#include <rtems/score/watchdog.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/**
* @defgroup ScoreMPPacket MP Packet Handler
*
@@ -33,14 +41,6 @@
*/
/**@{*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <rtems/score/object.h>
-#include <rtems/score/priority.h>
-#include <rtems/score/watchdog.h>
-
/**
* The following enumerated type defines the packet classes.
*
@@ -111,15 +111,11 @@ typedef struct {
#define MP_PACKET_MINIMUN_HETERO_CONVERSION \
( sizeof( MP_packet_Prefix ) / sizeof( uint32_t ) )
-#ifndef __RTEMS_APPLICATION__
-#include <rtems/score/mppkt.inl>
-#endif
+/**@}*/
#ifdef __cplusplus
}
#endif
-/**@}*/
-
#endif
/* end of include file */
diff --git a/cpukit/score/inline/rtems/score/mppkt.inl b/cpukit/score/inline/rtems/score/mppkt.inl
deleted file mode 100644
index 0f9c6b2..0000000
--- a/cpukit/score/inline/rtems/score/mppkt.inl
+++ /dev/null
@@ -1,61 +0,0 @@
-/**
- * @file
- *
- * @brief Inlined Routines from the Packet Handler
- *
- * This package is the implementation of the Packet Handler
- * routines which are inlined.
- */
-
-/*
- * COPYRIGHT (c) 1989-2004.
- * On-Line Applications Research Corporation (OAR).
- *
- * The license and distribution terms for this file may be
- * found in the file LICENSE in this distribution or at
- * http://www.rtems.com/license/LICENSE.
- */
-
-#ifndef _RTEMS_SCORE_MPPKT_H
-# error "Never use <rtems/score/mppkt.inl> directly; include <rtems/score/mppkt.h> instead."
-#endif
-
-#ifndef _RTEMS_SCORE_MPPKT_INL
-#define _RTEMS_SCORE_MPPKT_INL
-
-/**
- * @addtogroup ScoreMPPacket
- */
-/**@{**/
-
-/**
- * This function returns true if the the_packet_class is valid,
- * and false otherwise.
- *
- * @note Check for lower bounds (MP_PACKET_CLASSES_FIRST ) is unnecessary
- * because this enum starts at lower bound of zero.
- */
-
-RTEMS_INLINE_ROUTINE bool _Mp_packet_Is_valid_packet_class (
- MP_packet_Classes the_packet_class
-)
-{
- return ( the_packet_class <= MP_PACKET_CLASSES_LAST );
-}
-
-/**
- * This function returns true if the the_packet_class is null,
- * and false otherwise.
- */
-
-RTEMS_INLINE_ROUTINE bool _Mp_packet_Is_null (
- MP_packet_Prefix *the_packet
-)
-{
- return the_packet == NULL;
-}
-
-/** @} */
-
-#endif
-/* end of include file */
diff --git a/cpukit/score/preinstall.am b/cpukit/score/preinstall.am
index fc3b785..2ba6c86 100644
--- a/cpukit/score/preinstall.am
+++ b/cpukit/score/preinstall.am
@@ -343,8 +343,3 @@ $(PROJECT_INCLUDE)/rtems/score/tod.inl: inline/rtems/score/tod.inl $(PROJECT_INC
$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/score/tod.inl
PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/score/tod.inl
-if HAS_MP
-$(PROJECT_INCLUDE)/rtems/score/mppkt.inl: inline/rtems/score/mppkt.inl $(PROJECT_INCLUDE)/rtems/score/$(dirstamp)
- $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/score/mppkt.inl
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/score/mppkt.inl
-endif
More information about the vc
mailing list