You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2020/11/27 11:19:36 UTC
[incubator-nuttx] 29/48: arch/arm/src/cxd56xx/cxd56_wdt.c: Fix
syslog formats
This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit ea0537cfaf918dcd06f884f8449b998dbdebf42a
Author: YAMAMOTO Takashi <ya...@midokura.com>
AuthorDate: Thu Nov 26 17:37:02 2020 +0900
arch/arm/src/cxd56xx/cxd56_wdt.c: Fix syslog formats
---
arch/arm/src/cxd56xx/cxd56_wdt.c | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/arch/arm/src/cxd56xx/cxd56_wdt.c b/arch/arm/src/cxd56xx/cxd56_wdt.c
index ae78d49..e3c1b02 100644
--- a/arch/arm/src/cxd56xx/cxd56_wdt.c
+++ b/arch/arm/src/cxd56xx/cxd56_wdt.c
@@ -43,6 +43,7 @@
#endif
#include <nuttx/arch.h>
+#include <inttypes.h>
#include <stdint.h>
#include <errno.h>
@@ -411,9 +412,9 @@ static int cxd56_getstatus(FAR struct watchdog_lowerhalf_s *lower,
}
wdinfo("Status :\n");
- wdinfo(" flags : %08x\n", status->flags);
- wdinfo(" timeout : %d\n", status->timeout);
- wdinfo(" timeleft : %d\n", status->timeleft);
+ wdinfo(" flags : %08" PRIx32 "\n", status->flags);
+ wdinfo(" timeout : %" PRId32 "\n", status->timeout);
+ wdinfo(" timeleft : %" PRId32 "\n", status->timeleft);
return OK;
}
@@ -442,7 +443,7 @@ static int cxd56_settimeout(FAR struct watchdog_lowerhalf_s *lower,
uint64_t llreload;
DEBUGASSERT(priv);
- wdinfo("Entry: timeout=%d\n", timeout);
+ wdinfo("Entry: timeout=%" PRId32 "\n", timeout);
if ((timeout == 0) || (timeout > WDT_MAX_TIMEOUT))
{
@@ -482,7 +483,8 @@ static int cxd56_settimeout(FAR struct watchdog_lowerhalf_s *lower,
priv->reload = reload;
- wdinfo("reload=%u timeout: %d->%d\n", reload, timeout, priv->timeout);
+ wdinfo("reload=%" PRIu32 " timeout: %" PRId32 "->%" PRId32 "\n",
+ reload, timeout, priv->timeout);
/* Set the WDT register according to calculated value */