From b72a3640b368a558714e0acdceb1e9db5ef572ab Mon Sep 17 00:00:00 2001 From: Piotr Esden-Tempski Date: Sun, 7 Jul 2013 13:58:00 -0700 Subject: [PATCH] [CM0] Disabled sync for LPC43xx/M0. We are currently using the same code for CM0 CM3 and CM4 cores. This patch is a bodge that disables sync on the LPC43xx/M0 core, it would be nicer to probably implement a dispatch system similar to the one used in stm32 peripheral support so that we can accomodate the different features of the cortex cores. I (esden) assume we will run into more incompatibilities in the future between the cortex cores. --- lib/cm3/sync.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/cm3/sync.c b/lib/cm3/sync.c index 9257d397..88fe1114 100644 --- a/lib/cm3/sync.c +++ b/lib/cm3/sync.c @@ -19,6 +19,10 @@ #include +#if defined(LPC43XX_M0) +#warning "Currently sync is not supported on Cortex-M0" +#else + uint32_t __ldrex(volatile uint32_t *addr) { uint32_t res; @@ -66,3 +70,4 @@ void mutex_unlock(mutex_t *m) *m = MUTEX_UNLOCKED; } +#endif