You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by GitBox <gi...@apache.org> on 2020/08/20 20:04:02 UTC
[GitHub] [mynewt-core] andrzej-kaczmarek commented on a change in pull request #2359: hw/mcu/dialog: Add all reset reason checks
andrzej-kaczmarek commented on a change in pull request #2359:
URL: https://github.com/apache/mynewt-core/pull/2359#discussion_r474240221
##########
File path: hw/hal/include/hal/hal_system.h
##########
@@ -72,6 +72,10 @@ enum hal_reset_reason {
HAL_RESET_SYS_OFF_INT = 7,
/** Restart due to DFU */
HAL_RESET_DFU = 8,
+ /** Reserved 1 */
+ HAL_RESET_WATCHDOG2 = 9,
Review comment:
this file is common for all MCUs and imo it does not really need to have unique mapping for every single reset reason for each MCU. in this case, CMAC watchdog could be just mapped to `HAL_RESET_WATCHDOG`. in generic case, it would be just better to add `HAL_RESET_OTHER` and map any reset reason that does not map to defined value - MCU can provide `mcu_reset_cause` to read actual reset reason and appropriate `#define`s in `mcu.h`.
----------------------------------------------------------------
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