cm3: scb: C11 keyword compliance

Avoid use of the gnu specific "asm" keyword, and use the __asm__
keyword, as used everywhere else in the library.  This fixes compilation
in C11, and unifies all uses of asm literals in the codebase.

Reported-by: @dragonmux
Fixes: https://github.com/libopencm3/libopencm3/pull/1425

Signed-off-by: Karl Palsson <karlp@tweak.net.au>
This commit is contained in:
Karl Palsson
2022-07-05 16:52:43 +00:00
parent 4675227783
commit 44e142d4f9

View File

@@ -549,7 +549,7 @@ struct scb_exception_stack_frame {
#define SCB_GET_EXCEPTION_STACK_FRAME(f) \
do { \
asm volatile ("mov %[frameptr], sp" \
__asm__ volatile ("mov %[frameptr], sp" \
: [frameptr]"=r" (f)); \
} while (0)