File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change 28
28
29
29
#define _CONCAT (x ,y ) _CONCAT1(x,y)
30
30
#define _CONCAT1 (x ,y ) x ## y
31
- #define _STR (a ) #a
31
+ #define _STR_ (a ) #a
32
32
33
33
typedef __CHAR16_TYPE__ char16_t ;
34
34
35
35
#define __packed __attribute__((__packed__))
36
36
37
37
/* From FreeBSD: compile-time asserts */
38
- #define CTASSERT (x ) _Static_assert(x, _STR (x))
38
+ #define CTASSERT (x ) _Static_assert(x, _STR_ (x))
39
39
40
40
#define CTASSERT_SIZE_BYTE (t , s ) CTASSERT(sizeof(t) == (s))
41
41
#define CTASSERT_SIZE_BIT (t , s ) CTASSERT(sizeof(t) * 8 == (s))
Original file line number Diff line number Diff line change @@ -105,7 +105,11 @@ void __stack_chk_fail(void)
105
105
uint32_t sp = __get_MSP ();
106
106
print ("Stack overflow!" NL );
107
107
print (" SP = " );
108
+ #if defined(_bootloader_ )
108
109
printHex (sp );
110
+ #else
111
+ printHex32 (sp );
112
+ #endif
109
113
print (NL NL );
110
114
fault_isr ();
111
115
}
@@ -116,7 +120,11 @@ void unused_isr()
116
120
Cortex_IRQ irq = get_current_isr ();
117
121
print ("Unhandled ISR!" NL );
118
122
print (" IRQn = " );
123
+ #if defined(_bootloader_ )
119
124
printHex (irq );
125
+ #else
126
+ printHex32 (irq );
127
+ #endif
120
128
print (NL NL );
121
129
fault_isr ();
122
130
}
You can’t perform that action at this time.
0 commit comments