You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ma...@apache.org on 2024/04/21 09:40:06 UTC

(nuttx) branch master updated (3739a233b7 -> d0820acbbb)

This is an automated email from the ASF dual-hosted git repository.

masayuki pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


    from 3739a233b7 rp2040/w5500-evb-pico: Add documentation
     new 72548951d3 drivers: syslog: Replace sched_lock with critical section in syslog_flush_intbuffer()
     new d0820acbbb sched: misc: Remove sched_lock in _assert()

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 drivers/syslog/syslog_intbuffer.c | 5 +++--
 sched/misc/assert.c               | 4 ----
 2 files changed, 3 insertions(+), 6 deletions(-)


(nuttx) 02/02: sched: misc: Remove sched_lock in _assert()

Posted by ma...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

masayuki pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit d0820acbbba213dbb7e4d1b7f38b6564d265660e
Author: hujun5 <hu...@xiaomi.com>
AuthorDate: Thu Apr 18 21:23:36 2024 +0800

    sched: misc: Remove sched_lock in _assert()
    
    Signed-off-by: hujun5 <hu...@xiaomi.com>
---
 sched/misc/assert.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/sched/misc/assert.c b/sched/misc/assert.c
index 0079014782..343a042f76 100644
--- a/sched/misc/assert.c
+++ b/sched/misc/assert.c
@@ -536,8 +536,6 @@ void _assert(FAR const char *filename, int linenum,
 
   flags = enter_critical_section();
 
-  sched_lock();
-
   /* try to save current context if regs is null */
 
   if (regs == NULL)
@@ -672,7 +670,5 @@ void _assert(FAR const char *filename, int linenum,
 #endif
     }
 
-  sched_unlock();
-
   leave_critical_section(flags);
 }


(nuttx) 01/02: drivers: syslog: Replace sched_lock with critical section in syslog_flush_intbuffer()

Posted by ma...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

masayuki pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 72548951d374620792a3d80396de349702362e9d
Author: hujun5 <hu...@xiaomi.com>
AuthorDate: Thu Apr 18 21:19:35 2024 +0800

    drivers: syslog: Replace sched_lock with critical section in syslog_flush_intbuffer()
    
    Signed-off-by: hujun5 <hu...@xiaomi.com>
---
 drivers/syslog/syslog_intbuffer.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/syslog/syslog_intbuffer.c b/drivers/syslog/syslog_intbuffer.c
index 6347e179f0..cdff96df3a 100644
--- a/drivers/syslog/syslog_intbuffer.c
+++ b/drivers/syslog/syslog_intbuffer.c
@@ -249,6 +249,7 @@ int syslog_add_intbuffer(int ch)
 int syslog_flush_intbuffer(bool force)
 {
   syslog_putc_t putfunc;
+  irqstate_t flags;
   int ch;
   int i;
 
@@ -256,7 +257,7 @@ int syslog_flush_intbuffer(bool force)
    * concurrent modification by other tasks.
    */
 
-  sched_lock();
+  flags = enter_critical_section();
 
   do
     {
@@ -293,7 +294,7 @@ int syslog_flush_intbuffer(bool force)
     }
   while (ch != EOF);
 
-  sched_unlock();
+  leave_critical_section(flags);
 
   return ch;
 }