aboutsummaryrefslogtreecommitdiffstats
path: root/os/rt/include/chmemcore.h
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2015-03-05 21:28:51 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2015-03-05 21:28:51 +0000
commitb53489d0e4252aafe5ada7466e0b3b7c4ad5aaaf (patch)
tree2efd9ba0b52dfed9daefb6eb4d6b86b073776a21 /os/rt/include/chmemcore.h
parent880d6916b3fb25b3972ed78b380db630524623e7 (diff)
downloadChibiOS-b53489d0e4252aafe5ada7466e0b3b7c4ad5aaaf.tar.gz
ChibiOS-b53489d0e4252aafe5ada7466e0b3b7c4ad5aaaf.tar.bz2
ChibiOS-b53489d0e4252aafe5ada7466e0b3b7c4ad5aaaf.zip
Lots of MISRA-related changes in RT. Not finished yet.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7715 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/rt/include/chmemcore.h')
-rw-r--r--os/rt/include/chmemcore.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/os/rt/include/chmemcore.h b/os/rt/include/chmemcore.h
index fde35415d..33bafe072 100644
--- a/os/rt/include/chmemcore.h
+++ b/os/rt/include/chmemcore.h
@@ -28,7 +28,7 @@
#ifndef _CHMEMCORE_H_
#define _CHMEMCORE_H_
-#if CH_CFG_USE_MEMCORE || defined(__DOXYGEN__)
+#if (CH_CFG_USE_MEMCORE == TRUE) || defined(__DOXYGEN__)
/*===========================================================================*/
/* Module constants. */
@@ -68,7 +68,7 @@ typedef void *(*memgetfunc_t)(size_t size);
/**
* @brief Alignment mask constant.
*/
-#define MEM_ALIGN_MASK (MEM_ALIGN_SIZE - 1)
+#define MEM_ALIGN_MASK (MEM_ALIGN_SIZE - 1U)
/**
* @brief Alignment helper macro.
@@ -84,7 +84,7 @@ typedef void *(*memgetfunc_t)(size_t size);
* @brief Returns whatever a pointer or memory size is aligned to
* the type @p align_t.
*/
-#define MEM_IS_ALIGNED(p) (((size_t)(p) & MEM_ALIGN_MASK) == 0)
+#define MEM_IS_ALIGNED(p) (((size_t)(p) & MEM_ALIGN_MASK) == 0U)
/** @} */
/*===========================================================================*/
@@ -106,7 +106,7 @@ extern "C" {
/* Module inline functions. */
/*===========================================================================*/
-#endif /* CH_CFG_USE_MEMCORE */
+#endif /* CH_CFG_USE_MEMCORE == TRUE */
#endif /* _CHMEMCORE_H_ */