You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/05/08 16:52:44 UTC

[GitHub] [incubator-nuttx] patacongo commented on a change in pull request #1007: Move pthread-specific data into TLS

patacongo commented on a change in pull request #1007:
URL: https://github.com/apache/incubator-nuttx/pull/1007#discussion_r422252676



##########
File path: libs/libc/tls/Kconfig
##########
@@ -45,10 +45,11 @@ config TLS_LOG2_MAXSTACK
 
 config TLS_NELEM
 	int "Number of TLS elements"
-	default 0
+	default 4

Review comment:
       Yes, this was for backward compatibility.  When TLS and pthread-specific data were merged, the the old CONFIG_NPTHREAD_KEYS was replaced with CONFIG_TLS_ELEM since TLS is now the underlying mechanism.  In order to be backward compatible with existing defconfig files, CONFIG_TLS_NELEM must have the same default as CONFIG_PTHREAD_KEYS used to have, that is four.
   
   In most defconfig files, pthread-specific data is disabled like:
   
       -CONFIG_NPTHREAD_KEYS=0
       +CONFIG_TLS_NELEM=0
   
   So there will be no impact to the the behavior of any of the configurations.  So although this looks weird, this is the correct default to have absolutely no impact on the existing configurations.
   




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org