Gary-Hobson commented on code in PR #7981:
URL: https://github.com/apache/nuttx/pull/7981#discussion_r1058721291


##########
drivers/note/notelog_driver.c:
##########
@@ -320,37 +410,20 @@ void sched_note_spinlock(FAR struct tcb_s *tcb,
 #endif
 
 #ifdef CONFIG_SCHED_INSTRUMENTATION_SYSCALL
-void sched_note_syscall_enter(int nr, int argc, ...)
+static void notelog_syscall_enter(FAR struct note_driver_s *drv, int nr)
 {
-  char buf[128];
-  FAR char *p = buf;
-  va_list ap;
-
-  va_start(ap, argc);
-  while (argc-- > 0)
-    {
-      if (argc)
-        {
-          p += sprintf(p, "%#"PRIxPTR", ", va_arg(ap, uintptr_t));
-        }
-      else
-        {
-          p += sprintf(p, "%#"PRIxPTR, va_arg(ap, uintptr_t));
-        }
-    }
-
-  va_end(ap);
-  syslog(LOG_INFO, "%s@%d ENTER %s\n", g_funcnames[nr], nr, buf);
+  syslog(LOG_INFO, "%s@%d ENTER %s\n", g_funcnames[nr], nr);
 }
 
-void sched_note_syscall_leave(int nr, uintptr_t result)
+static void notelog_syscall_leave(FAR struct note_driver_s *drv, int nr)

Review Comment:
   syslog is a system call, sched_note_syscall_xxx cannot be used in notelog



##########
include/nuttx/note/note_driver.h:
##########
@@ -103,6 +103,12 @@ struct note_driver_s
   FAR const struct note_driver_ops_s *ops;
 };
 
+/****************************************************************************
+ * Public Data
+ ****************************************************************************/
+
+extern struct note_driver_s g_notelog_driver;

Review Comment:
   done



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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to