aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabio Utzig <utzig@utzig.org>2016-05-25 19:04:42 -0300
committerFabio Utzig <utzig@utzig.org>2016-05-25 19:04:42 -0300
commit209c3566776302eddb7819ff6c6dcfc645edff90 (patch)
treedb243ceded7504b40fc8645513c48d8270b13c3f
parente1311c4db6cd366cf760673f769e925741ac0ad3 (diff)
parent3cde591bd28011e76cbeb56996dec8a9d151b9b6 (diff)
downloadChibiOS-Contrib-209c3566776302eddb7819ff6c6dcfc645edff90.tar.gz
ChibiOS-Contrib-209c3566776302eddb7819ff6c6dcfc645edff90.tar.bz2
ChibiOS-Contrib-209c3566776302eddb7819ff6c6dcfc645edff90.zip
Merge pull request #78 from flabbergast/kinetis
[KINETIS] Fixes for kernel-less builds.
-rw-r--r--os/hal/boards/PJRC_TEENSY_LC/board.c1
-rw-r--r--os/hal/ports/KINETIS/LLD/hal_i2c_lld.h4
-rw-r--r--os/hal/ports/KINETIS/LLD/hal_pal_lld.c4
-rw-r--r--os/hal/ports/KINETIS/LLD/hal_usb_lld.c2
4 files changed, 3 insertions, 8 deletions
diff --git a/os/hal/boards/PJRC_TEENSY_LC/board.c b/os/hal/boards/PJRC_TEENSY_LC/board.c
index 31c3ca4..ab321b8 100644
--- a/os/hal/boards/PJRC_TEENSY_LC/board.c
+++ b/os/hal/boards/PJRC_TEENSY_LC/board.c
@@ -14,7 +14,6 @@
limitations under the License.
*/
-#include "ch.h"
#include "hal.h"
#if HAL_USE_PAL || defined(__DOXYGEN__)
diff --git a/os/hal/ports/KINETIS/LLD/hal_i2c_lld.h b/os/hal/ports/KINETIS/LLD/hal_i2c_lld.h
index 3576b60..bfc5008 100644
--- a/os/hal/ports/KINETIS/LLD/hal_i2c_lld.h
+++ b/os/hal/ports/KINETIS/LLD/hal_i2c_lld.h
@@ -157,14 +157,10 @@ struct I2CDriver {
*/
i2cflags_t errors;
#if I2C_USE_MUTUAL_EXCLUSION || defined(__DOXYGEN__)
-#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__)
/**
* @brief Mutex protecting the bus.
*/
mutex_t mutex;
-#elif CH_CFG_USE_SEMAPHORES
- semaphore_t semaphore;
-#endif
#endif /* I2C_USE_MUTUAL_EXCLUSION */
#if defined(I2C_DRIVER_EXT_FIELDS)
I2C_DRIVER_EXT_FIELDS
diff --git a/os/hal/ports/KINETIS/LLD/hal_pal_lld.c b/os/hal/ports/KINETIS/LLD/hal_pal_lld.c
index b307833..51f8a2e 100644
--- a/os/hal/ports/KINETIS/LLD/hal_pal_lld.c
+++ b/os/hal/ports/KINETIS/LLD/hal_pal_lld.c
@@ -108,7 +108,7 @@ void _pal_lld_setpadmode(ioportid_t port,
PORT_TypeDef *portcfg = NULL;
- chDbgAssert(pad < PADS_PER_PORT, "pal_lld_setpadmode() #1, invalid pad");
+ osalDbgAssert(pad < PADS_PER_PORT, "pal_lld_setpadmode() #1, invalid pad");
if (mode == PAL_MODE_OUTPUT_PUSHPULL)
port->PDDR |= ((uint32_t) 1 << pad);
@@ -126,7 +126,7 @@ void _pal_lld_setpadmode(ioportid_t port,
else if (port == IOPORT5)
portcfg = PORTE;
- chDbgAssert(portcfg != NULL, "pal_lld_setpadmode() #2, invalid port");
+ osalDbgAssert(portcfg != NULL, "pal_lld_setpadmode() #2, invalid port");
switch (mode) {
case PAL_MODE_RESET:
diff --git a/os/hal/ports/KINETIS/LLD/hal_usb_lld.c b/os/hal/ports/KINETIS/LLD/hal_usb_lld.c
index 159aef9..e8d9778 100644
--- a/os/hal/ports/KINETIS/LLD/hal_usb_lld.c
+++ b/os/hal/ports/KINETIS/LLD/hal_usb_lld.c
@@ -420,7 +420,7 @@ void usb_lld_init(void) {
}
}
usbfrac_match_found:
- chDbgAssert(i<2 && j <8,"USB Init error");
+ osalDbgAssert(i<2 && j <8,"USB Init error");
#else /* KINETIS_MCG_MODE == KINETIS_MCG_MODE_PEE */
#error USB clock setting not implemented for this KINETIS_MCG_MODE