summaryrefslogtreecommitdiffstats
path: root/cpukit/include/rtems/posix
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2018-10-14 19:20:05 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2018-10-29 10:33:37 +0100
commite97806a5ff7673422082edd49ec3c62c5f0f1ccd (patch)
tree05d82a61ba2453ec0e9354f42797c560031ca88b /cpukit/include/rtems/posix
parentMove default config to librtemsdefaultconfig.a (diff)
downloadrtems-e97806a5ff7673422082edd49ec3c62c5f0f1ccd.tar.bz2
posix: Split posix_api_configuration_table
Use separate configuration variables to avoid false dependencies. Update #2514.
Diffstat (limited to 'cpukit/include/rtems/posix')
-rw-r--r--cpukit/include/rtems/posix/config.h66
-rw-r--r--cpukit/include/rtems/posix/mqueue.h2
-rw-r--r--cpukit/include/rtems/posix/psignal.h2
-rw-r--r--cpukit/include/rtems/posix/pthread.h3
-rw-r--r--cpukit/include/rtems/posix/semaphore.h2
-rw-r--r--cpukit/include/rtems/posix/shm.h4
-rw-r--r--cpukit/include/rtems/posix/timer.h2
7 files changed, 17 insertions, 64 deletions
diff --git a/cpukit/include/rtems/posix/config.h b/cpukit/include/rtems/posix/config.h
index e90dc27011..e6b5870ac7 100644
--- a/cpukit/include/rtems/posix/config.h
+++ b/cpukit/include/rtems/posix/config.h
@@ -46,70 +46,10 @@ typedef struct {
int stack_size;
} posix_initialization_threads_table;
-/**
- * The following records define the POSIX Configuration Table.
- * The information contained in this table is required in all
- * RTEMS systems which include POSIX threads support, whether
- * single or multiprocessor. This table primarily defines the
- * following:
- *
- * + required number of each object type
- */
-typedef struct {
- /**
- * This field contains the maximum number of POSIX API
- * threads which are configured for this application.
- */
- uint32_t maximum_threads;
-
- /**
- * This field contains the maximum number of POSIX API
- * timers which are configured for this application.
- */
- uint32_t maximum_timers;
-
- /**
- * This field contains the maximum number of POSIX API
- * queued signals which are configured for this application.
- */
- uint32_t maximum_queued_signals;
-
- /**
- * This field contains the maximum number of POSIX API
- * message queues which are configured for this application.
- */
- uint32_t maximum_message_queues;
+extern posix_initialization_threads_table * const
+ _Configuration_POSIX_Initialization_threads;
- /**
- * This field contains the maximum number of POSIX API
- * semaphores which are configured for this application.
- */
- uint32_t maximum_semaphores;
-
- /**
- * Maximum configured number of POSIX Shared memory objects.
- */
- uint32_t maximum_shms;
-
- /**
- * This field contains the number of POSIX API Initialization
- * threads listed in @a User_initialization_thread_table.
- */
- uint32_t number_of_initialization_threads;
-
- /**
- * This field contains the list of POSIX API Initialization threads.
- */
- posix_initialization_threads_table *User_initialization_threads_table;
-} posix_api_configuration_table;
-
-/**
- * @brief POSIX API configuration table.
- *
- * This is the POSIX API Configuration Table expected to be generated
- * by confdefs.h.
- */
-extern posix_api_configuration_table Configuration_POSIX_API;
+extern const size_t _Configuration_POSIX_Initialization_thread_count;
/**@}*/
#ifdef __cplusplus
diff --git a/cpukit/include/rtems/posix/mqueue.h b/cpukit/include/rtems/posix/mqueue.h
index cdf94514af..6211c68783 100644
--- a/cpukit/include/rtems/posix/mqueue.h
+++ b/cpukit/include/rtems/posix/mqueue.h
@@ -61,6 +61,8 @@ typedef struct {
int oflag;
} POSIX_Message_queue_Control;
+extern const uint32_t _Configuration_POSIX_Maximum_message_queues;
+
/** @} */
#ifdef __cplusplus
diff --git a/cpukit/include/rtems/posix/psignal.h b/cpukit/include/rtems/posix/psignal.h
index ed98442e32..52a9ec6caf 100644
--- a/cpukit/include/rtems/posix/psignal.h
+++ b/cpukit/include/rtems/posix/psignal.h
@@ -31,5 +31,7 @@ typedef struct {
siginfo_t Info;
} POSIX_signals_Siginfo_node;
+extern const uint32_t _Configuration_POSIX_Maximum_queued_signals;
+
#endif
/* end of file */
diff --git a/cpukit/include/rtems/posix/pthread.h b/cpukit/include/rtems/posix/pthread.h
index bf46253776..25bf40ef27 100644
--- a/cpukit/include/rtems/posix/pthread.h
+++ b/cpukit/include/rtems/posix/pthread.h
@@ -19,7 +19,6 @@
#ifndef _RTEMS_POSIX_PTHREAD_H
#define _RTEMS_POSIX_PTHREAD_H
-#include <rtems/posix/config.h>
#include <rtems/posix/threadsup.h>
#include <rtems/score/thread.h>
@@ -39,6 +38,8 @@ extern "C" {
extern const size_t _Configuration_POSIX_Minimum_stack_size;
+extern const uint32_t _Configuration_POSIX_Maximum_threads;
+
/**
* @brief POSIX threads initialize user threads body.
*
diff --git a/cpukit/include/rtems/posix/semaphore.h b/cpukit/include/rtems/posix/semaphore.h
index 9133db22be..734d8bb84b 100644
--- a/cpukit/include/rtems/posix/semaphore.h
+++ b/cpukit/include/rtems/posix/semaphore.h
@@ -46,6 +46,8 @@ typedef struct {
uint32_t open_count;
} POSIX_Semaphore_Control;
+extern const uint32_t _Configuration_POSIX_Maximum_named_semaphores;
+
/** @} */
#ifdef __cplusplus
diff --git a/cpukit/include/rtems/posix/shm.h b/cpukit/include/rtems/posix/shm.h
index d2b6036493..310af6692b 100644
--- a/cpukit/include/rtems/posix/shm.h
+++ b/cpukit/include/rtems/posix/shm.h
@@ -18,6 +18,8 @@
#include <rtems/score/object.h>
#include <rtems/score/threadq.h>
+#include <sys/types.h>
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -124,6 +126,8 @@ typedef struct {
time_t ctime;
} POSIX_Shm_Control;
+extern const uint32_t _Configuration_POSIX_Maximum_shms;
+
/**
* @brief object_create operation for shm objects stored in RTEMS Workspace.
*/
diff --git a/cpukit/include/rtems/posix/timer.h b/cpukit/include/rtems/posix/timer.h
index 79fe093219..52732af991 100644
--- a/cpukit/include/rtems/posix/timer.h
+++ b/cpukit/include/rtems/posix/timer.h
@@ -50,6 +50,8 @@ typedef struct {
struct timespec time; /* Time at which the timer was started */
} POSIX_Timer_Control;
+extern const uint32_t _Configuration_POSIX_Maximum_timers;
+
/** @} */
#ifdef __cplusplus