pkarashchenko commented on a change in pull request #4999:
URL: https://github.com/apache/incubator-nuttx/pull/4999#discussion_r770262566



##########
File path: include/nuttx/sched_note.h
##########
@@ -99,6 +99,15 @@
   memset((s), 0, sizeof(struct note_filter_irq_s))
 #endif
 
+/* Note dump module tag definitions */
+
+#ifdef CONFIG_SCHED_INSTRUMENTATION_DUMP
+#  define NOTE_MODULE(a, b, c, d) \
+  ((unsigned)(a) | ((unsigned)(b) << 8) | ((unsigned)(c) << 16) | ((d) << 24))

Review comment:
       Actually if any of `a`, `b` or `c` are not byte size them result value 
will be wrong.
   If you want to write reliable macro you need to add `& 0xff` to each 
argument.




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