linguini1 commented on code in PR #18300:
URL: https://github.com/apache/nuttx/pull/18300#discussion_r2756268922


##########
arch/arm/src/stm32h7/stm32_fdcan_sock.c:
##########
@@ -2066,6 +2065,10 @@ int fdcan_initialize(struct fdcan_driver_s *priv)
 
   fdcan_setconfig(priv->base, 1);
 
+  /* Clear Message RAM */
+
+  memset((void *)STM32_CANRAM_BASE, 0, 2560 * 4);

Review Comment:
   Is this a necessary operation? Can the memory be left uninitialized?
   
   I would suggest using `define` macros to replace the magic numbers 2560 and 
4 so that readers know what those numbers refer to.



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