arch: raise an error when compiling for an unknown ARM platform
authorSitsofe Wheeler <sitsofe@yahoo.com>
Sun, 9 Jul 2017 07:32:47 +0000 (08:32 +0100)
committerSitsofe Wheeler <sitsofe@yahoo.com>
Thu, 27 Jul 2017 05:15:00 +0000 (06:15 +0100)
The nop, read_barrier() and write_barrier() macros have to always be
defined but due to the way os/arch-arm.h is written it is possible for
them to be undefined when the ARM platform is not recognized.

Change things so compiling for an unknown ARM platform raises an
explicit compilation error at the point of the problem.

Signed-off-by: Sitsofe Wheeler <sitsofe@yahoo.com>
arch/arch-arm.h

index 31671fdbe7283ba9007c8c25901dde1cc776aad5..dd286d04464f20bbb3aabbb3997f8b410af325f1 100644 (file)
@@ -14,6 +14,8 @@
 #define        nop             __asm__ __volatile__ ("nop")
 #define read_barrier() __sync_synchronize()
 #define write_barrier()        __sync_synchronize()
+#else
+#error "unsupported ARM architecture"
 #endif
 
 #endif