From 62443700cb8aafb4f18b994267d973a7346b6a2c Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Sat, 6 Jun 2020 11:19:11 +0000 Subject: [PATCH] Fixed bug #985. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/stable_20.3.x@13688 27425a3e-05d8-49a3-a47f-9c15f0e5edd8 --- os/common/ports/ARMCMx/chcore_v6m.h | 11 ++++++++--- readme.txt | 1 + 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/os/common/ports/ARMCMx/chcore_v6m.h b/os/common/ports/ARMCMx/chcore_v6m.h index f1e58b213..371397ed8 100644 --- a/os/common/ports/ARMCMx/chcore_v6m.h +++ b/os/common/ports/ARMCMx/chcore_v6m.h @@ -128,9 +128,14 @@ /* Handling a GCC problem impacting ARMv6-M.*/ #if defined(__GNUC__) && !defined(PORT_IGNORE_GCC_VERSION_CHECK) -#if __GNUC__ > 5 -#warning "This compiler has a know problem with Cortex-M0, see bugs: 88167, 88656." -#warning "*** Use GCC version 5 or below ***" +#if ( __GNUC__ > 5 ) && ( __GNUC__ < 10 ) +#define GCC_VERSION ( __GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ ) +#if ( __GNUC__ == 7 ) && ( GCC_VERSION >= 70500 ) +#elif ( __GNUC__ == 8 ) && ( GCC_VERSION >= 80400 ) +#elif ( __GNUC__ == 9 ) && ( GCC_VERSION >= 90300 ) +#else +#warning "This compiler has a know problem with Cortex-M0, see GCC bugs: 88167, 88656." +#endif #endif #endif diff --git a/readme.txt b/readme.txt index 42021de01..1dbad823b 100644 --- a/readme.txt +++ b/readme.txt @@ -74,6 +74,7 @@ ***************************************************************************** *** 20.3.2 *** +- FIX: Fixed GCC6 problem breaks Cortex-M0 port (bug #985). - FIX: Fixed a wrong management of the SPI TX buffer in the ADUCM port (bug #1103). - FIX: Fixed STM32F4 EFL sector bug (bug #1102).