1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

cpu/{atxmega,atmega_common}: fix invalid use of PSTR()

core_panic() doesn't expect the message to be in program memory, but
in data memory. Bad things will happen on AVR when the address is
interpreted as being in data address space, but the allocation is
done in program address space.
This commit is contained in:
Marian Buschsieweke 2021-09-30 15:25:21 +02:00
parent 7bfc1814ae
commit 35a1b60068
No known key found for this signature in database
GPG Key ID: 61F64C6599B1539F
2 changed files with 2 additions and 9 deletions

View File

@ -26,8 +26,6 @@
* @}
*/
#include <avr/pgmspace.h>
#include "board.h"
#include "cpu.h"
#include "panic.h"
@ -100,8 +98,7 @@ ISR(BADISR_vect)
LED_PANIC;
#endif
core_panic(PANIC_GENERAL_ERROR, PSTR("FATAL ERROR: BADISR_vect called, unprocessed Interrupt.\n"
"STOP Execution.\n"));
core_panic(PANIC_GENERAL_ERROR, "BADISR");
}
#if defined(CPU_ATMEGA128RFA1) || defined (CPU_ATMEGA256RFR2)

View File

@ -18,8 +18,6 @@
* @}
*/
#include <avr/pgmspace.h>
#include "cpu.h"
#include "cpu_clock.h"
#include "cpu_pm.h"
@ -121,7 +119,5 @@ ISR(BADISR_vect)
LED_PANIC;
#endif
core_panic(PANIC_GENERAL_ERROR,
PSTR("FATAL ERROR: BADISR_vect called, unprocessed Interrupt.\n"
"STOP Execution.\n"));
core_panic(PANIC_GENERAL_ERROR, "BADISR");
}