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/11 06:22:18 UTC

[GitHub] [incubator-nuttx] YuuichiNakamura commented on a change in pull request #1023: Fix setlogmask() not to use enter_critical_section() in protected build

YuuichiNakamura commented on a change in pull request #1023:
URL: https://github.com/apache/incubator-nuttx/pull/1023#discussion_r422806850



##########
File path: libs/libc/syslog/lib_setlogmask.c
##########
@@ -91,17 +96,29 @@ uint8_t g_syslog_mask = LOG_ALL;
 int setlogmask(int mask)
 {
   uint8_t oldmask;
+
+#if defined(CONFIG_BUILD_FLAT) || defined(__KERNEL__)

Review comment:
       Thanks and sorry for my incomplete understanding for NuttX task group model. I found that pthread_mutex is not prefer for this case.
   
   As the Greg's last comment in ML, Do I just need to remove the critical section in this case because setlogmask() have no need to concern about MT-safe ?
   




----------------------------------------------------------------
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