Skip to content

Commit c83858b

Browse files
Gary-Hobsonxiaoxiang781216
authored andcommitted
note: fix note_common unaligned access
Data in ARMV8-M may be aligned with less than 4 bytes, resulting in USAGE FAULT Signed-off-by: yinshengkai <[email protected]>
1 parent 464d284 commit c83858b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/note/note_driver.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1441,7 +1441,7 @@ void sched_note_event_ip(uint32_t tag, uintptr_t ip, uint8_t event,
14411441
FAR struct note_event_s *note;
14421442
FAR struct note_driver_s **driver;
14431443
bool formatted = false;
1444-
char data[255];
1444+
char data[256];
14451445
unsigned int length;
14461446
FAR struct tcb_s *tcb = this_task();
14471447

@@ -1491,7 +1491,7 @@ void sched_note_vprintf_ip(uint32_t tag, uintptr_t ip, FAR const char *fmt,
14911491
FAR struct note_printf_s *note;
14921492
FAR struct note_driver_s **driver;
14931493
bool formatted = false;
1494-
uint8_t data[255];
1494+
uint8_t data[256];
14951495
size_t length = 0;
14961496
FAR struct tcb_s *tcb = this_task();
14971497

0 commit comments

Comments
 (0)