diff --git a/arch/arm/src/armv7-m/arm_exception.S b/arch/arm/src/armv7-m/arm_exception.S index d2478aadd2..4f057ae113 100644 --- a/arch/arm/src/armv7-m/arm_exception.S +++ b/arch/arm/src/armv7-m/arm_exception.S @@ -87,9 +87,12 @@ ****************************************************************************/ .globl exception_common - +#ifdef __ghs__ + .thumb2 +#else .syntax unified .thumb +#endif .file "arm_exception.S" /**************************************************************************** @@ -119,8 +122,12 @@ .text .section .text.exception_common +#ifdef __ghs__ + .type exception_common, $function +#else .thumb_func .type exception_common, function +#endif exception_common: mrs r0, ipsr /* R0=exception number */ diff --git a/arch/arm/src/armv7-m/arm_saveusercontext.S b/arch/arm/src/armv7-m/arm_saveusercontext.S index 58d02f575f..5e67be0e6c 100644 --- a/arch/arm/src/armv7-m/arm_saveusercontext.S +++ b/arch/arm/src/armv7-m/arm_saveusercontext.S @@ -28,8 +28,12 @@ .file "arm_saveusercontext.S" .text +#ifdef __ghs__ + .thumb2 +#else .syntax unified .thumb +#endif /**************************************************************************** * Public Functions @@ -52,7 +56,11 @@ .globl up_saveusercontext .globl up_saveusercontext +#ifdef __ghs__ + .type up_saveusercontext, $function +#else .type up_saveusercontext, %function +#endif up_saveusercontext: diff --git a/arch/arm/src/common/gnu/fork.S b/arch/arm/src/common/gnu/fork.S index 7697561a27..d98003d4da 100644 --- a/arch/arm/src/common/gnu/fork.S +++ b/arch/arm/src/common/gnu/fork.S @@ -26,7 +26,6 @@ #include "arm_fork.h" - .syntax unified .file "fork.S" /**************************************************************************** @@ -78,7 +77,11 @@ ****************************************************************************/ .globl up_fork +#ifdef __ghs__ + .type up_fork, $function +#else .type up_fork, function +#endif up_fork: /* Create a stack frame */