summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2014-05-21 09:18:29 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2014-05-21 09:41:01 +0200
commit884a6c59ba418017db4b5239283f3d436a12b849 (patch)
treee7b73664cd97a236f4518b6a919e930bc1b98cc8
parentscore: Simplify _Scheduler_Set() (diff)
downloadrtems-884a6c59ba418017db4b5239283f3d436a12b849.tar.bz2
score: Add comment regarding TLS workspace size
-rw-r--r--cpukit/score/src/wkspace.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/cpukit/score/src/wkspace.c b/cpukit/score/src/wkspace.c
index 1dda9f124c..94ce5cb397 100644
--- a/cpukit/score/src/wkspace.c
+++ b/cpukit/score/src/wkspace.c
@@ -66,6 +66,14 @@ void _Workspace_Handler_initialization(
uintptr_t tls_size = _TLS_Get_size();
size_t i;
+ /*
+ * In case we have a non-zero TLS size, then we need a TLS area for each
+ * thread. These areas are allocated from the workspace. Ensure that the
+ * workspace is large enough to fulfill all requests known at configuration
+ * time (so excluding the unlimited option). It is not possible to estimate
+ * the TLS size in the configuration at compile-time. The TLS size is
+ * determined at application link-time.
+ */
if ( tls_size > 0 ) {
uintptr_t tls_align = _TLS_Heap_align_up( (uintptr_t) _TLS_Alignment );
uintptr_t tls_alloc = _TLS_Get_allocation_size( tls_size, tls_align );